Submission #43315

#TimeUsernameProblemLanguageResultExecution timeMemory
43315shihabsarar29Sequence (BOI14_sequence)C++14
0 / 100
2 ms352 KiB
#include<bits/stdc++.h> using namespace std; int A[200000]; int main() { int K,i; scanf("%d",&K); for(i=0;i<K;i++) scanf("%d",&A[i]); i=0; if(K==1) printf("%d\n",A[i]); else if(K<=10) printf("%d\n",A[i]*10); else if(K<=100) printf("%d\n",A[i]*100); else if(K<=1000) printf("%d\n",A[i]*1000); else if(K<=10000) printf("%d\n",A[i]*10000); else if(K<=100000) printf("%d\n",A[i]*100000); }

Compilation message (stderr)

sequence.cpp: In function 'int main()':
sequence.cpp:9:18: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
    scanf("%d",&K);
                  ^
sequence.cpp:11:24: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
       scanf("%d",&A[i]);
                        ^
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...