strange_device.cpp: In function 'int main()':
strange_device.cpp:26:24: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::pair<long long int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
26 | for (int i = 0; i < E.size(); ) {
| ~~^~~~~~~~~~
strange_device.cpp:27:33: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::pair<long long int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
27 | NOW = E[i].f; while (i < E.size() && E[i].f == NOW) cur += E[i++].s; ans++;
| ~~^~~~~~~~~~
strange_device.cpp:29:10: warning: this 'if' clause does not guard... [-Wmisleading-indentation]
29 | if (prev > 0) ans += NOW - PREV - 1; prev = cur; PREV = NOW;
| ^~
strange_device.cpp:29:47: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
29 | if (prev > 0) ans += NOW - PREV - 1; prev = cur; PREV = NOW;
| ^~~~