my first java program successful : exam mark percentage.

package com.company;
import java.util.Scanner;
public class tut4 {
public static void main(String[]args){
int math=10;
int eng=5;
int hind=2;
int sci= 1;
int sum=math + eng + hind+ sci;
System.out.print("the sum is:");
System.out.println(sum);
System.out.println(" the percenteges is:% ");
int per = sum * 100/20 ;

System.out.println(per);
}
}

output

the sum is:18

 the percenteges is:% 

90


Comments

Popular posts from this blog

Gove confirms mandatory housebuilding targets for councils will be abolished in face of Tory rebellion – UK politics live

Kotak Mahindra Bank Recruitment 2022 Released for Graduate Candidates And Apply Online