I have the below piece of code. I want to create an object Model outside my main and then use it inside main method. However, VS keeps confusing my object initialization with a function declaration and doesnt allow me to use it. Is there a way to initialize it without the compiler confusing between the two?
Model model();
int main{
model.loadModel("testModel.txt"); // I want to do st like this, but it causes error
}
How can I fix this?