knapsack.cpp: In function 'int main()':
knapsack.cpp:10:10: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
10 | scanf("%d %d", &N, &X);
| ~~~~~^~~~~~~~~~~~~~~~~
knapsack.cpp:11:38: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
11 | for(int i = 0; i < N; i++) scanf("%d", &h[i]);
| ~~~~~^~~~~~~~~~~~~
knapsack.cpp:12:38: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
12 | for(int i = 0; i < N; i++) scanf("%d", &s[i]);
| ~~~~~^~~~~~~~~~~~~
knapsack.cpp:13:38: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
13 | for(int i = 0; i < N; i++) scanf("%d", &k[i]);
| ~~~~~^~~~~~~~~~~~~