how to call one program .class file in another program
Answer Posted / sudarshan kumar
public class Hello{
int a=5;
void sum(){
int s=a+10;
System.out.print("\n sum :: "+s);
}
}
class Client{
public static void main(String x[]){
Hello h=new Hello()
h.sum();
}
}
| Is This Answer Correct ? | 4 Yes | 1 No |
Post New Answer View All Answers
How does the java compiler work?
What is array in java?
Explain JMS in detail.
Can you extend main method in java?
What causes memory leaks in java?
Can singleton class be serialized?
What is a boolean used for?
I want to store more than 10 objects in a remote server? Which methodology will follow?
How do you invoke a method?
Explain the difference between comparator and comparable in java?
What is a constructor, constructor overloading in java?
What is difference between this and super keyword?
How do you sort an array in java?
Why do we use threads in java?
does java support pointers?