Computer Applications
When a method is invoked how many values can be returned from the method?
User Defined Methods
47 Likes
Answer
A method can only return a single value.
Answered By
25 Likes
Related Questions
What are the two ways of invoking methods?
When a method returns the value, the entire method call can be assigned to a variable. Do you agree with the statement?
Debug the errors and rewrite the following method prototypes:
(a) int sum(x,y);
(b) float product(a,int y);
(c) float operate(int x, float=3.4);
(d) float sum(int x,y);
Write down the main method which calls the following method:
int square(int a) { return(a*a); }