what is the output???????
public class multireturn
{
public(int assign x ( int x)
{
if(4==x)
{
return 7;
}
else if (7=x+3)
{
return 6;
}
return 5;
}
}
Answer Posted / amit singh
answer is that compile time error
because what you did i don't know what i saw i know
else if(7=x+3)
it not a condition you are using the assignment operator
in place of (7==x+3)
amitsing2008@gmail.com
| Is This Answer Correct ? | 7 Yes | 0 No |
Post New Answer View All Answers
Why stringbuilder is not thread safe?
What is a method in programming?
What is the purpose of the file class in java programming?
How large is a boolean?
How do you use compareto in java?
What is a bufferedreader?
Can you declare the main method as final?
Explain what is encapsulation?
What is a line separator in java?
What is java used for?
Does windows 10 need java?
Can we convert stringbuffer to string?
What is method in java with example?
What is purpose of keyword void?
What are the principle concepts of oops?