一枚渣子


私信TA

用户名:uq_44501180482

访问量:16668

签 名:

笨蛋

等  级
排  名 26
经  验 16313
参赛次数 1
文章发表 238
年  龄 0
在职情况 在职
学  校 河南科技大学
专  业

  自我简介:

渣子

import java.util.Scanner;

public class Main {

		public static void main(String[] args) {
			Scanner sc=new Scanner(System.in);
			int n=sc.nextInt();
			int MaxAward=0;String stuname="";
			int sumAll=0;
			for (int i = 0; i < n; i++) {
				int sum=0;
				String name=sc.next();
				int score1=sc.nextInt();//期末平均成绩
				int score2=sc.nextInt();//班级评议成绩
				char  bgb=sc.next().charAt(0);
				char  west=sc.next().charAt(0);
				int paper=sc.nextInt();
				if(score1>80&&paper>=1){ sum+=8000; sumAll+=8000;}
				if(score1>85&&score2>80){ sum+=4000; sumAll+=4000;}
				if(score1>90){ sum+=2000;sumAll+=2000;}
				if(score1>85&&west=='Y') { sum+=1000;sumAll+=1000;}
				if(score2>80&&bgb=='Y') { sum+=850;sumAll+=850;}
				if(sum>MaxAward){MaxAward=sum; stuname=name;}
			}
			System.out.printf("%s\n%d\n%d",stuname,MaxAward,sumAll);
			
		}
	}


 

0.0分

1 人评分

  评论区

  • «
  • »