Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 02-05-2008, 08:25 PM
Member
 
Join Date: Feb 2008
Posts: 6
diRisig is on a distinguished road
Pass by ref. A work around?
Hello,

I'm horrified to learn that in Java all variables are passed to methods by value.
I want to write a function that will fit an exponential function(y = A*exp(B*x) ) to some data. In C++ I would just pass the data along with references to variables for A and B to a method and have the method manipulate A and B.

In java it seems I need to have two different methods; one to return A and one to return B.

Is there a way around this?

Thanks
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Question on how to pass text of a pulldown Brucifer New To Java 0 04-03-2008 12:23 AM
how to pass array in java? sivasayanth New To Java 3 01-13-2008 05:33 PM
Cannot pass the correct property value to a form piterskiy74 Web Frameworks 0 12-11-2007 04:17 PM
How to pass an html variable as an applet value fred Java Applets 1 08-06-2007 04:28 AM
I can't seem to pass the value of a string variable into a string array mathias Java Applets 1 08-03-2007 11:52 AM


All times are GMT +3. The time now is 04:18 PM.


VBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org