Problem flappyrabbit
User PlayVoltz
Submission Time 2023-08-23 21:40:39
Score 0
Max Time N/A
Max Memory N/A

Compile Error

flappyrabbit.cpp: In function ‘int min_fuel(int, int)’:
flappyrabbit.cpp:13:15: error: ‘INT_MAX’ was not declared in this scope
13 | int minnum = INT_MAX, maxnum = INT_MIN;
| ^~~~~~~
flappyrabbit.cpp:2:1: note: ‘INT_MAX’ is defined in header ‘<climits>’; did you forget to ‘#include <climits>’?
1 | #include "flappyrabbit.h"
+++ |+#include <climits>
2 | #include <vector>
flappyrabbit.cpp:15:3: error: ‘maxnum’ was not declared in this scope; did you mean ‘minnum’?
15 | maxnum = max(maxnum, down[i]);
| ^~~~~~
| minnum
flappyrabbit.cpp:20:13: error: ‘maxnum’ was not declared in this scope; did you mean ‘minnum’?
20 | return max(maxnum-minnum, 0);
| ^~~~~~
| minnum