Computer Science, asked by haridraaa, 11 hours ago

Write a program in Java to accept student’s name and marks scored in physics, chemistry and biology. Check and display the greatest marks along with student name.
Program must be written with

variable Description

please try to answer
I will surely mark u as BRAINLIST​

Answers

Answered by lk4507099
3

Answer:

import java.util.Scanner; public class KboatAvgNStream { public static void main(String args[]) { Scanner in = new Scanner(System.in); System.out.print("Enter marks in Physics: "); int phy = in.nextInt(); System.out.print("Enter marks in Chemistry: "); int chem = in.nextInt(); System.out.print("Enter marks in Biology: "); int bio = in.nextInt(); double avg = (phy + chem + bio) / 3.0; if (avg < 40) System.out.println("No stream"); else if (avg < 60) System.out.println("Commerce"); else if (avg < 80) System.out.println("Bio-Science"); else System.out.println("Computer Science"); }

Explanation:

drop some thanks follow and mark me as brainlist

Similar questions