Submission #1088416

#TimeUsernameProblemLanguageResultExecution timeMemory
1088416SunbaeProsjek (COCI14_prosjek)C++17
50 / 50
1 ms348 KiB
#include <cstdio> int b[101]; signed main(){ int n; scanf("%d", &n); for(int i = 1; i<=n; ++i){ scanf("%d", b+i); b[i] *= i; printf("%d ", b[i] - b[i-1]); } }

Compilation message (stderr)

prosjek.cpp: In function 'int main()':
prosjek.cpp:4:14: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
    4 |  int n; scanf("%d", &n);
      |         ~~~~~^~~~~~~~~~
prosjek.cpp:6:8: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
    6 |   scanf("%d", b+i); b[i] *= i;
      |   ~~~~~^~~~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...