Untitled

 avatar
unknown
plain_text
4 years ago
561 B
4
Indexable
import java.util.Scanner;

public class App {
    public static void main(String[] args) throws Exception {
        System.out.println("Hello, World!");
        Scanner input = new Scanner(System.in);

        System.out.print("Please enter a no:");
        int mark = input.nextInt();
        if (mark >=0 && mark <=100)
            System.out.print(mark +" is a valid mark.");
        else if (mark <0)
            System.out.print(mark +" is not a valid mark.");
        else
            System.out.print(mark + " is a valid mark");
    }
}
Editor is loading...