Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

static method query?

 
kiran kumar
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
class A{
static void methodA(){
System.out.println("in methodA");
}
public static void main(String ar[]){
A a1=new A();
a1.methodA(); //when we have to use this one
A.methodA(); //when we have to use this one

}
 
Rodrigo Lopes
Ranch Hand
Posts: 119
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Read this
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic