Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

What are keywords in java?

949


What is 32 bit float?

925


Difference between overriding and overloading in java?

1008


Write down program for following scenario. Use java coding standard. You have array list with some words in it..we will call it as dictionary….and you have a arbitrary string containing some chars in it. You have to go through each word of dictionary and find out if that word can be constructed with the help of chars from arbitrary string given. If you find the word print it else print none.

2667


What are java methods?

1037


Explain implementation and how is it different from conversion?

1018


Why object class is super class for every class in java?

963


Can we have multiple classes in a single file?

913


Is constructor inherited?

913


When do I need to use reflection feature in java?

1008


Write a java program for binary search?

1008


What is thread start?

913


Can we override constructor?

968


Explain about complier design(phases)

1023


What is method in java with example?

900