Answer Posted / atul
class mainoverloaded
{
public void main()
{
System.out.println("Hey");
}
public void main(int a)
{
System.out.println(a);
}
}
class maind
{
public static void main(String ah[])
{
mainoverloaded m=new mainoverloaded();
m.main();
m.main(10);
}
}
please execute this code.it is execute correctly.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is jvm? Why is java called the platform independent programming language?
What is the intersection and union methods?
difference between byte stream class and character stream class?
How does java pattern compile work?
Can we override the static methods?
What is the protected method modifier?
What is the difference between preemptive scheduling and time slicing?
What is instanceof keyword?
How to create an interface?
What is the difference between jvm and jre? What is an interface?
What do u mean by variable?
What is a variable simple definition?
What is functional interface in java?
Can we override static methods in java?
is there a separate stack for each thread in java? : Java thread