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 / guest

7 or 5 depending on value of x but never 6

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What happens if we don’t define serial version uid?

576


Can a method be overloaded based on different return type but same argument type?

554


What is java volatile?

553


What is composition in java?

734


When we should use serialization?

576






What is the console in java?

686


What are format specifiers in java?

612


What does string intern() method do?

594


How will you add panel to a frame?

659


Explain OOPs concept.

657


Is minecraft java edition free?

591


What data type is a string?

517


How can you make sure that your singleton class will always return single instance in multi-threaded environment?

579


why java uses class level type casting ?

2261


What is the diffrence between inner class and nested class?

571