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...

In which way does a Primitive data type is passed ?

Answer Posted / sailendra.n.jena

primitive datatype are pass this way
class A
{
int x=7;
void disp(int z)
{
System.out.println(z);
}
}
class Test
{
public static void main(String args[])
{
int x=7;
A a=new A();
a.disp(x);
}
when u pass the primtive reference to this method only
address will transfer to the parameter which i have given
to the void disp(int z).After passing the reference
variable the other variable will pointing to that object &
collect the value of that object.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

hr interview how many minutes asking question

2042


What is purpose of keyword void?

1041


What is anagram word?

993


What do you mean by byte code?

1001


How do I convert a string to an int in java?

1069


What are three advantages of using functions?

1005


Explain the usage of this with constructors?

1025


What is the full form of jpeg?

955


Which programming language is best in future?

959


Can java list contain duplicates?

1008


What is exception hierarchy in java?

1006


How many tetrahedral voids are there in bcc?

1092


Which access specifier can be used with class ?

996


What is compareto () in java?

972


How do you check if a character in a string is a digit or letter?

1070