subsequence.cpp: In function 'int main()':
subsequence.cpp:13:12: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
13 | freopen("subsequence.in", "r", stdin); freopen("subsequence.out", "w", stdout);
| ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
subsequence.cpp:13:51: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
13 | freopen("subsequence.in", "r", stdin); freopen("subsequence.out", "w", stdout);
| ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
subsequence.cpp:15:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
15 | scanf("%d", &n);
| ~~~~~^~~~~~~~~~
subsequence.cpp:17:38: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
17 | for (int i = 0; i < n; ++i) scanf("%d", &a[i]);
| ~~~~~^~~~~~~~~~~~~
subsequence.cpp:18:38: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
18 | for (int i = 0; i < n; ++i) scanf("%d", &k[i]); //purpose of k[0]
| ~~~~~^~~~~~~~~~~~~