+ 1

Explain this please:

int a,b,c,d,e; a=5; b=6; c=8; d=9; e=15; String name1,name2,name3,name4,name5; name1="sugat"; name2="shiva"; name3="madhav"; name4="kabin"; name5="anil"; if (a>b && a>c && a>d && a>e && a>b || a>c || a>d || a>e ){ System.out.println(name1); } else if(b>a && b>c && b>d && b>e && b>a || b>c || b>d || b>e ){ System.out.println(name2); } else if(c>a && c>b && c>d && c>e && c>a || c>b || c>d || c>e){ System.out.println(name3); } else if(d>a && d>b && d>c && d>e && d>a || d>b || d>c || d>e ){ System.out.println(name4); } else if(e>a && e>b && e>c && e>d && e>a || e>b || e>c || e>d ){ System.out.println(name5); } else { System.out.println("no name"); }

16th Oct 2018, 7:16 AM
su zayn
su zayn - avatar
3 odpowiedzi
+ 3
// Please, use the code playground to run the code.
16th Oct 2018, 7:24 AM
program
program - avatar
+ 1
thanks supriya for your help 🙂
17th Oct 2018, 7:51 AM
su zayn
su zayn - avatar
0
bro explain how the result come as madhav, i mean why not anil
16th Oct 2018, 7:43 AM
su zayn
su zayn - avatar