java - What is wrong with my if-else syntax? -
currently new java, , right i'm doing assignment involving if else statements. can please why javac
reading else dangling? syntax should right unless missing here.
you have remove semicolon after if-statement. otherwise braces after if not executed.
i hope fix problem.
if(statement); { //the content not executed in realtion if-statemen }
otherwise:
if(statement) { //the content executed in realtion if-statemen }