Submission #608968

#TimeUsernameProblemLanguageResultExecution timeMemory
608968sword060Zamjena (COCI18_zamjena)C++17
14 / 70
3 ms1640 KiB
#include <bits/stdc++.h> using namespace std; int main(){ ios::sync_with_stdio(0); cin.tie(0); int x;cin>>x; string a[x],b[x]; for(int i=0;i<x;i++)cin>>a[i]; for(int i=0;i<x;i++)cin>>b[i]; for(int i=0;i<x;i++){ bool f1=!(a[i][0]>='0'&&a[i][0]<='9'); bool f2=!(b[i][0]>='0'&&b[i][0]<='9'); if(f1&&f2)continue; else if(f1){ if(a[i].size()>b[i].size()){cout<<"NE";return 0;} }else if(f2){ if(a[i].size()<b[i].size()){cout<<"NE";return 0;} }else{ if(a[i]!=b[i]){cout<<"NE";return 0;} } } cout<<"DA"; return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...