Preview:
import java.util.Scanner;

public class Task7{
	public static void main(String args[]){
		Scanner input = new Scanner(System.in);
		
		System.out.println("Enter the age: ");
		int age = input.nextInt();
		System.out.println("Enter marks in maths: ");
		double mathMarks = input.nextDouble();
		System.out.println("Enter marks in english: ");
		double englishMarks = input.nextDouble();
		System.out.println("Enter marks in science: ");
		double scienceMarks = input.nextDouble();
		
		double totalMarks = mathMarks + englishMarks + scienceMarks;
		
		if(age > 15 && mathMarks >= 65 && englishMarks >= 55 && scienceMarks > 50 && totalMarks >= 180){
			System.out.println("Eligible for admission!");
		}
		else{
			System.out.println("Not eligible for admission");
		}
		
	}
}
downloadDownload PNG downloadDownload JPEG downloadDownload SVG

Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!

Click to optimize width for Twitter