Code outside functions

You can’t write code outside of functions. The only things you can have outside of functions are declarations such as global variable declarations (usually a bad idea), function declarations etc. Try putting it in a function like int main(){}

Leave a Comment