New Member FAQ
|
Forums
|
Earn Revenue
Resources
Entrance
Ask Experts
Exam Papers
Jobs
English
Projects
Universities
Colleges
Courses
Schools
Training
My India
Members
|
Communities
|
Business Directory
|
Classifieds
|
Reviews
|
Silverlight Games
|
Peer Appraisal
|
Bookmarks
|
Polls
|
Mentors
|
Links
|
MCA Projects
|
Lobby
|
Gift Shop
|
Chat
My Profile
Sign In
Register
AdSense Revenue
Active Members
Today
MVR PURNA ...
(170)
Vandana
(90)
Mr. Anindya
(89)
Last 7 Days
PROSENJIT MANN...
(1979)
Aira
(1426)
Shobha Manasa
(1419)
more...
Awards & Gifts
Online Exams
Aptitude Questions
General Aptitude Tests
Medical Entrance
Engineering Entrance
Bank Tests
TOEFL & IELTS Questions
Fresher Jobs
Our fresher job section is exclusively for fresh graduates! Find jobs for freshers in major Indian cities including Bangalore, Chennai, Hyderabad, Pune or Kochi
Resources
Find educational articles, blogs, discussion threads and other resources.
Colleges
Find details about any college in India or search for courses.
Passing values - Java
Posted Date: Total Responses:
0
Posted By:
Annapurna
Member Level:
Gold
Points/Cash
: 1
public class PassingValue {
static int i = 0 ;
void increase (int i) {
++i;
}
void increase(PassingValue p)
{
System.out.println ("p.i in method " +p.i) ;
++p.i;
}
public static void main(String args [ ] ) {
PassingValue p = new PassingValue () ;
p.increase (i) ; // It can't change the i value.
System.out.println (i) ;
p.increase(p); //It can change the i value.
System.out.println ("p.i" +i) ;
}
}
Project Feedbacks
No feedbacks found. Be the first to respond and make money from
revenue sharing program
.
Post Feedback
You must
Sign In
to post a feedback.
Next Project:
Example program for Null Pointer Exception - Java
Previous Project:
Example of Initialization - Java
Return to Project Index
Post New Project
Related Projects
Java program that reads a file and displays the file on the screen
Optimal program
Adding Huge Numbers in C
How to clear IE cache through vb.net
To find the relation with your friends(Flames) by C language
Advertise Here
Contact Us
Advertise
Editors
Privacy Policy
Terms Of Use
ISC Technologies.
2006 - 2009 All Rights Reserved.