Computer Science, asked by varshinimuralidhar, 6 months ago

Some one should teach me if-else in JAVA

Answers

Answered by BrainlyProgrammer
2

Answer:

if-else? it's very easy...

see..

for example.... I say...

if u score 90% in computer I will give u dairy milk...or if u score 80%...i will give u kurkure... otherwise... I will give u slap..

so if I say this using if else...

if (score==90)

System.out.println("Dairy milk") ;

else if (score==80) //here 'else if' represent or'r in the above example....

System.out.println("Kurkure") ;

else //here 'else' represent 'otherwise' in the above example

System.out.println("I will slap u") ;

now u see... is there any difference....no... u can jst compare this as if u are applying conditions

Similar questions