Examveda

Which return statement correctly returns the output?

A.

public int cube(int x)
{
    return (x + x);
}

B.

public int cube(int x)
return (x + x);

C.

public int cube(int x)
{
    return x + x;
}

D. None of the mentioned

Answer: Option A


Join The Discussion

Related Questions on Classes and Objects in C Sharp