I am a noob in Java and am someone who is learning Java after python. Anyways, I am having a hard time figuring this out. Suppose I have the class
class Bicycle{
....
}
and
public class Bicycle{
....}
what is the difference. And what about
public static class Bicycle{
// if this can be a valid class def in first place
}
and then, after this.. lets talk about variables.
class Bicycle{
int Gear or public int Gear // whats the difference
}
When to use which one?