Good day,
I am fairly new to Java. The first language I started learning was C++. With C++ I used a new .cpp file to spread my code to multiple files, so it doesn't get too clustered. I would only use classes when needed (for example categorizing students from a school by their name, address, phone number etc.). But now that I changed to Java, I have trouble understanding how to use classes, when I don't want to categorize something. Lets say I want to spread my code in multiple .java files, so it doesn't get clustered. When creating a new .java file, it automatically creates a new class. So my question would be: If I don't plan using the class the conventional way, what would be the solution: declaring all methods and variables as static inside the new class in the new .java file, or create only one instance of the class and use this instance through the rest of the code? And is the correct approach (using static vs instance) still correct when using JavaFX?