From 0bc90d8f8d783fbd1b410dd93da201e9f09672cf Mon Sep 17 00:00:00 2001 From: wang-jiawen-rjjs <2903977615@qq.com> Date: Tue, 13 Apr 2021 22:09:31 +0800 Subject: [PATCH] =?UTF-8?q?=E7=8E=8B=E4=BD=B3=E6=96=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Demo01.java" | 36 +++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 "\346\225\260\347\273\204\347\273\203\344\271\240/\347\216\213\344\275\263\346\226\207/Demo01.java" diff --git "a/\346\225\260\347\273\204\347\273\203\344\271\240/\347\216\213\344\275\263\346\226\207/Demo01.java" "b/\346\225\260\347\273\204\347\273\203\344\271\240/\347\216\213\344\275\263\346\226\207/Demo01.java" new file mode 100644 index 0000000..45dc7ac --- /dev/null +++ "b/\346\225\260\347\273\204\347\273\203\344\271\240/\347\216\213\344\275\263\346\226\207/Demo01.java" @@ -0,0 +1,36 @@ +import java.util.Scanner;; +public class Demo01 { + + public static void main(String[] args) { + Scanner s = new Scanner(System.in); + int [] Scorearr=new int [6]; + int max; + int min; + int sum=0; + max=Scorearr[0]; + for(int i=0;iScorearr[i]) { + min=Scorearr[i]; + } + } + System.out.println("最小值为"+min); + for(int i=0;i200) { + System.out.println("请输入正确分数"); + }else { + sum=sum+Scorearr[i]; + } + } + System.out.println("平均分为"+(sum-max-min)/4); + + } +} -- Gitee