By admin on December 27, 2010
Please don’t give me some internet dictionary definition with words i have no idea how to explain…
what is parameter and why would we want to use a parameter in a method
A parameter is sometimes described as “acting as a placeholder.” What does this mean?
Posted in Computer Science Dictionary | Tagged definition, dictionary definition, idea, internet dictionary, parameter, placeholder |
Incoming search terms:
what does parameter mean, parameter computer science, what does parameters mean, what does parameter mean in java, parameters computer science, what is a parameter in computer science, computer science parameter, parameters in computer science, what are parameters in computing, what are parameters in computer science
a method is like a procedure of a series of steps
parameter is information given to the procedure
for example, say your method calculates 1 + x. the parameter would be x
here it is visually sort of, say you want to make a method that finds the sum of 2 numbers.
int sum(int x1, int x2) // “int x1″ is parameter 1 and “int x2″ is parameter 2
{
return x1 + x2
}
2 values are being passed into the method with 2 parameters