Java If else

package Javaifelse;

public class java {

public static void main(String[] args) {
// TODO Auto-generated method stub
int a=10;
if(a>11) {
System.out.println(true);
}
else {
System.out.println(false);
}
}
public static void main(String[] args) {
    // TODO Auto-generated method stub
    int a=10;
    if(a>11) {
        System.out.println(true);
    }
    else {
        System.out.println(false);

    }
}
public static void main(String[] args) { // TODO Auto-generated method stub int a=10; if(a>11) { System.out.println(true); } else { System.out.println(false); } }

Enter fullscreen mode Exit fullscreen mode

}
If else statement is a condition statement that is used in the execution of a computer program in pre-defined rules. The if-else statement helps you to run a specific block of a program if the condition is true or else, it will check other conditions.23_

原文链接:Java If else

© 版权声明
THE END
喜欢就支持一下吧
点赞11 分享
I may not be perfect but at least I’m not fake.
我可能不完美,但是我至少不虚伪
评论 抢沙发

请登录后发表评论

    暂无评论内容