Help me I'm noob
Hello, I'm noob (sorry bad english).
I come from javascript.
I need help.
Here is my code:
```
#include <stdio.h>
int debug_log(int n){
printf("%d\n", n);
}
int main(){
int i = 0;
while (i < 1000000){
debug_log(i);
i = i + 2;
}
}
```
I started by adding 1 to i every loop time, but it was slow. It was run for 119 seconds.
Then I decided to add 2 for more performance (optimization trick I learned) and it was run for 62 seconds.
The problem: it was faster (that is what I wanted) but now the log don't work well anymore. Now it shows more numbers. Is it because my computer's ram is stuck on first number or do I need to cear the cache before adding 2? I found no stack overflow subject on it. Do you also had this problem before? I'm on Windows 11. I'm scared I will break the compiler forever if I keep doing it.
Please help.
Posted Jun 11, 2026, 10:38 PM UTC · locked