There are currently no frequently asked questions associated with this exercise – that’s where you come in! You can contribute to this section by offering your own questions, answers, or clarifications on this exercise. Ask or answer a question by clicking reply () below.
If you’ve had an “aha” moment about the concepts, formatting, syntax, or anything else with this exercise, consider sharing those insights! Teaching others and answering their questions is one of the best ways to learn and stay sharp.
Join the Discussion. Help a fellow learner on their journey.
Ask or answer a question about this exercise by clicking reply () below!
Agree with a comment or answer? Like () to up-vote the contribution!
Ive gotten the second part of this wrong for simply not having a space between the closing bracket and args in the main method. In other words this will come back as incorrect because there it’s not (String args)
public class Store{
public static void main(Stringargs){
So, beginner here, got stuck in this exercise, was asked to [In the code editor, create a publicStore class.] but when I type code
public class Store {
// scope of Car class starts after curly brace
//I basically type on my own and try for three times, and on fourth attempts i copy the example
}
I gave above codes as answer and hit the blue-run-button, return a LOADING and this message [Error: Main method not found in class Store, please define the main method as:
public static void main(String args)
or a JavaFX application class must extend javafx.application.Application] so I was stuck.
What goes wrong? With my limited experience I think I did correctly created a public Store.class , any idea Senpai?
… should have a total of two sets of curly braces: one for the scope of the class, and one to define the scope of the main method. … needing a set of curly braces after public static void main(String args){
}
If you guys are getting error for some reason even if you’re actually correct, you just have to add space right after the class Store and right after the before “args”.