| | |
help with questions
Please support our Java advertiser: Programming Forums - DaniWeb Sister Site
![]() |
•
•
Join Date: Aug 2004
Posts: 2
Reputation:
Solved Threads: 0
hi guys can you help me with sum questions for my project im struggling with these four questions. thank you
wat are "formal parameters" and "actual values"? and how do we pass data into a function using parametrs
Write the sub definition of a function called example1 which uses two parameters (one an integer and one boolean)and returns an integer.
Do we always need to use a variable to store the value returned from a java function? Explain your answer with example code(snippets).
What syntax do we use in java to indicatethat we are passing a whole array as a parameter to a function(you should consider both the function definition and the function call)?
wat are "formal parameters" and "actual values"? and how do we pass data into a function using parametrs
Write the sub definition of a function called example1 which uses two parameters (one an integer and one boolean)and returns an integer.
Do we always need to use a variable to store the value returned from a java function? Explain your answer with example code(snippets).
What syntax do we use in java to indicatethat we are passing a whole array as a parameter to a function(you should consider both the function definition and the function call)?
I think these are not project questions. You can find the answers to these questions in you java book.
Anywayz ... here are some hints.
Parameters are values that are passed to functions for the function to use those values. e.g, public void function(int a){} ... here int a is a parameter.
You can get yourself going by reading further about passing parameters by value, and passing by reference.
No we dont always need to store the value returned by a function but it is not usually a good programming practice.
array passing is done like this. public void function( int []a){}
Anywayz ... here are some hints.
Parameters are values that are passed to functions for the function to use those values. e.g, public void function(int a){} ... here int a is a parameter.
You can get yourself going by reading further about passing parameters by value, and passing by reference.
No we dont always need to store the value returned by a function but it is not usually a good programming practice.
array passing is done like this. public void function( int []a){}
![]() |
Similar Threads
- I have a few questions to be patched up can anybody get these to me ? (C++)
- Questions about Forum (Geeks' Lounge)
- Preparing for an interview and need some questions answered (C)
- Wireless Questions (Networking Hardware Configuration)
- Linux printing questions (*nix Hardware Configuration)
- Tutorials & Code Submissions - Questions? (DaniWeb Community Feedback)
Other Threads in the Java Forum
- Previous Thread: jbuilder question
- Next Thread: Threading question...
| Thread Tools | Search this Thread |
911 actionlistener addressbook android api append applet application array arrays automation binary bluetooth character chat class classes client code component consumer csv database desktop eclipse error event exception fractal ftp game givemetehcodez graphics gui html ide image input integer j2me japplet java javaarraylist javac javaee javaprojects jmf jni jpanel julia linked linux list loop mac map method methods mobile netbeans newbie objects online oriented panel print printf problem program programming project projects properties recursion replaydirector reporting researchinmotion robot rotatetext rsa scanner screen se server set size sms sort sql string swing template test threads time tree ubuntu update windows working






