I'm trying out the syntax in C, as it's new to me. I was just starting with arrays, loops and random numbers, so I wrote this really simple test code:
I compile it with gcc and run from command prompt. Runs fine, prints each element in the array... And then crashes. Why? Is there something with the code logic?
Thank you in advance! This is my first question here, so I apologize in advance if I made any mistakes in question asking rules.
closed as off-topic by lurker, melpomene, ikegami, user3386109, Sneftel Feb 12 at 19:35
This question appears to be off-topic. The users who voted to close gave this specific reason:
If this question can be reworded to fit the rules in the help center, please edit the question.
- "This question was caused by a problem that can no longer be reproduced or a simple typographical error. While similar questions may be on-topic here, this one was resolved in a manner unlikely to help future readers. This can often be avoided by identifying and closely inspecting the shortest program necessary to reproduce the problem before posting." – lurker, melpomene, ikegami, user3386109, Sneftel