Java Quiz 1

package test1;//信1805-1 张志流 20183638
import java.util.Scanner;
public class ScoreManagement
{
static double sj;
static double yj;
static double jj;
static double gj;
static double rj;
static double pj;


I int;
public static void main (String args [])
{

zhujiemian ();


}
public static void tuichujiemian ()
{
System.out.println ( "******************************************************** ********************************************** ");
System .out.println ( "Thank you for the use of Shijiazhuang Railway Institute of software Engineering student management system");
System.out.println ( "producer: Zhang stream");
System.out.println ( "******** ************************************************** ***** ");
}
public static void zhujiemian ()
{
System.out.println (" *************************** ************************************ ");
System.out.println (" software Shijiazhuang Railway Institute Engineering ");
System.out.println (" student management system 2019 Edition ");
System.out.println ( "******************************************* ******************** ");
System.out.println (" 1, student test scores entry ");
System.out.println (" 2, student test performance modification ");
System.out.println (" 3, calculate student achievement Grade point ");
System.out.println (" 4, quit school management system ");
System.out.println (" ***** ************************************************** ******** ");
ScoreInformatio STU1 [] = new new ScoreInformatio [. 5];
STU1 [0] .name =" Zhang flow ";
STU1 [0] .stunumber =" 20,183,638 ";
STU1 [0] .mathematicsscore 0.0 =;
STU1 [0] = 0.0 .englishiscore;
STU1 [0] = 0.0 .networkscore;
STU1 [0] = 0.0 .databasescore;
STU1 [0] = 0.0 .softwarescore;

Scanner Scanner new new INPUT = (the System.in);
int j=input.nextInt();
int i;

Switch (J)
{
Case. 1: chengjilurujiemain ();
String Number = input.next ();
IF (Number == STU1 [0] .stunumber);
{
chengjilurujiemianer ();
System.out.println ( "Please enter the number of high results: ");
STU1 [0] = .mathematicsscore input.nextInt ();
chengjilurujiemianer ();
System.out.println (" score of the high number of "+ STU1 [0] .mathematicsscore +" ");
System.out.println ( "Please enter university English scores:");
STU1 [0] = .englishiscore input.nextInt ();
chengjilurujiemianer ();
System.out.println ( "the high number of score of" + stu1 [0] .mathematicsscore + "") ;
System.out.println ( "College English score of" + STU1 [0] .englishiscore + "");
IF (STU1 [0] == .networkscore 0.0)
System.out.println ( "Please enter the computer network performance:" );
stu1[0].networkscore=input.nextInt();
chengjilurujiemianer ();
System.out.println ( "the high number of score of" + STU1 [0] .mathematicsscore + "");
System.out.println ( "College English score of" + stu1 [0] .englishiscore + "");
System.out.println ( "computer network score of" + STU1 [0] .networkscore + "");
System.out.println ( "Please enter the data structure results:");
STU1 [0] = .databasescore input.nextInt ( );
chengjilurujiemianer ();
System.out.println ( "the high number of score of" + STU1 [0] .mathematicsscore + "");
System.out.println ( "College English score of" + stu1 [0] .englishiscore + "" );
System.out.println ( "computer network score of" + STU1 [0] .networkscore + "");
System.out.println ( "data structure score of" + STU1 [0] .databasescore + "");
the System. out.println ( "Please enter the software Engineering results:");
STU1 [0] = .softwarescore input.nextInt ();
chengjilurujiemianer ();
System.out.println ( "the high number of score of" + STU1 [0] .mathematicsscore + "");
System.out.println ( "College English score of" + STU1 [0] .englishiscore + "");
System.out. println ( "computer network score of" + STU1 [0] .networkscore + "");
System.out.println ( "data structure score of" + STU1 [0] .databasescore + "");
System.out.println ( "software Engineering score of "+ STU1 [0] .softwarescore +" ");
System.out.println (" the student score input completion, whether to submit (the Y / N) ");
System.out.println (" ***** ************************************************** *************************************** ");

SJ = jidian (STU1 [0] .mathematicsscore);
YJ = jidian (STU1 [0] .englishiscore);
JJ = jidian (STU1 [0] .networkscore);
GJ = jidian (STU1 [0] .databasescore);
RJ = jidian (STU1 [0] .softwarescore);
double pjj = (stu1 [0] .mathematicsscore * 4 + stu1 [0] .englishiscore * 3 + stu1 [0] .networkscore * 4 + stu1 [0] .databasescore * 3 + stu1 [0] .softwarescore * 2) / 16;
PJ = jidian (PJJ);
}
xuanze ();
BREAK;
Case 2: xiugaichengji ();
I = input.nextInt ();
Switch (I)
{
Case. 1: System.out.println ( "Please enter and modified Higher math: ");
STU1 [0] = .mathematicsscore input.nextInt ();
BREAK;
Case 2: System.out.println (" Please enter university English scores revised: ");
STU1 [0]. = input.nextInt englishiscore ();
BREAK;
Case. 3: System.out.println ( "Please enter the computer network modified score:");
STU1 [0] = .networkscore input.nextInt ();
BREAK;
Case. 4: System.out.println ( "Please enter the data structure of the modified score:");
STU1 [0] = .databasescore input.nextInt ();
BREAK;
Case 5: System.out.println ( "Please enter the modified software engineering achievement:");
STU1 [0] = .softwarescore input.nextInt ();
BREAK;
}
chengjilurujiemianer ();
System.out.println ( "the high number of score of" + STU1 [0] .mathematicsscore + "");
System.out.println ( "College English score of" + stu1 [0] .englishiscore + " ");
System.out.println (" computer network score of "+ STU1 [0] .networkscore +" ");
System.out.println (" data structure score of "+ STU1 [0] .databasescore +" ");
the System .out.println ( "software Engineering score of" + STU1 [0] .softwarescore + "");
System.out.println ( "the student achievement input is completed, whether or not to submit (the Y-/ N)");
System.out.println ( '****************************************************************");
xuanze();
break;
case 3:


chengjijidian ();
xuanze ();
BREAK;
Case. 4:
tuichujiemian ();
BREAK;



}
}
public static void chengjilurujiemain ()
{
System.out.println ( "*************** **************************** ") ;
System.out.println ( "Shijiazhuang Railway Institute of software Engineering student management system version 2019");
System.out.println ( "student test scores entry");
System.out.println ( "****** ************************************************** ******* ");
System.out.println (" enter the student number: ");
System.out.println (" ***************** ********************************************** ");
}
static void chengjilurujiemianer public ()
{
System.out.println ( "******************************************* ******************** ");
System.out.println (" Shijiazhuang Railway Institute of software Engineering student management system version 2019 ");
System.out.println ( "student test scores entry");
System.out.println ( "********************************** **************************************************************** ");
System.out.println (" candidates Student ID: "+ ScoreInformatio.stunumber +" " );
System.out.println ( "candidates name:" + ScoreInformatio.name + "");
System.out.println ( "********************** ****************************************** ");

}
public static void chengjijidian ()
{
System.out.println ( "**************************************** ************************ ");
System.out.println ("Software Engineering Student Management System version 2019 Shijiazhuang Railway Institute ");
System.out.println (" student test scores to calculate grade point Interface ");
System.out.println ( "******************************************* ************************************************************ ");
System.out.println (" No candidate Science: "ScoreInformatio.stunumber + +" ");
System.out.println ( "candidates name:" + ScoreInformatio.name + "");
System.out.println ( "1, higher math scores for Grade point:" + SJ + "");
System.out.println ( "2, in achievement Grade point Average: "+ YJ +" ");
System.out.println (". 3, the computer network GPA results: "JJ + +" ");
System.out.println (". 4, the data structure of GPA results: "+ gj +" ") ;
System.out.println ( "5, software engineering achievement grade point:" RJ + + "");
System.out.println ( "your grade point average is:" + PJ + "");
IF (PJ> = 2)
System.out.println ( "message: you have reached Grade point graduation requirements!");
the else
System.out.println ( "message: Your Grade Point does not meet the requirements for graduation!");
System.out.println ( "whether to return the system home page: (Y / N)") ;
System.out.println ( "******************************************* ************************************************************ ");
}
public static void xiugaichengji ()
{
System.out.println (" ********** ************************************************** ***** ");
System.out.println (" Shijiazhuang Railway Institute of software Engineering student management system version 2019 ");
System.out.println (" student test scores input interface ");
System.out.println ( "**************************** ****************** ");
System.out.println (" candidates Student ID: "ScoreInformatio.stunumber + +" ");
System.out.println (" candidates name : "+ ScoreInformatio.name +" ");

}
public static Double jidian (n-Double)
{
Double S = 0;
IF (n-<60)
S = 0;
else if(n>=60&&n<63.5)
s=1.0;
else if(n>=64&&n<65.9)
s=1.5;
else if(n>=66&&n<67.9)
s=1.7;
else if(n>=68&&n<71.5)
s=2.0;
else if(n>=72&&n<74.5)
s=2.3;
else if(n>=75&&n<77.9)
s=2.7;
else if(n>=78&&n<81.9)
s=3.0;
else if(n>=82&&n<84.5)
s=3.3;
else if(n>=85&&n<89.9)
s=3.7;
else if(n>=90)
s=4.0;
return s;
}
public static void xuanze()
{
String c;
Scanner input=new Scanner(System.in);
c=input.next();
char x=c.charAt(0);
if(x=='Y')
zhujiemian();
else if(x=='N');


}

}

 

 

 

 

 

 

 

package test1;//信1805-1 张志流 20183638
import java.util.Scanner;
public class ScoreManagement
{
static double sj;
static double yj;
static double jj;
static double gj;
static double rj;
static double pj;


I int;
public static void main (String args [])
{

zhujiemian ();


}
public static void tuichujiemian ()
{
System.out.println ( "******************************************************** ********************************************** ");
System .out.println ( "Thank you for the use of Shijiazhuang Railway Institute of software Engineering student management system");
System.out.println ( "producer: Zhang stream");
System.out.println ( "******** ************************************************** ***** ");
}
public static void zhujiemian ()
{
System.out.println (" *************************** ************************************ ");
System.out.println (" software Shijiazhuang Railway Institute Engineering ");
System.out.println (" student management system 2019 Edition ");
System.out.println ( "******************************************* ******************** ");
System.out.println (" 1, student test scores entry ");
System.out.println (" 2, student test performance modification ");
System.out.println (" 3, calculate student achievement Grade point ");
System.out.println (" 4, quit school management system ");
System.out.println (" ***** ************************************************** ******** ");
ScoreInformatio STU1 [] = new new ScoreInformatio [. 5];
STU1 [0] .name =" Zhang flow ";
STU1 [0] .stunumber =" 20,183,638 ";

stu1[0].mathematicsscore=0.0;

STU1 [0] = 0.0 .englishiscore;
STU1 [0] = 0.0 .networkscore;
STU1 [0] = 0.0 .databasescore;
STU1 [0] = 0.0 .softwarescore;

Scanner Scanner new new INPUT = (the System.in);
int J = input.nextInt ();
int I;

Switch (J)
{
Case. 1: chengjilurujiemain ();
String Number = input.next ();
IF (Number == STU1 [0] .stunumber);
{
chengjilurujiemianer ();
the System. out.println ( "Please enter the number of high results:");
STU1 [0] = .mathematicsscore input.nextInt ();
chengjilurujiemianer ();
System.out.println ( "score of the high number of" + stu1 [0] .mathematicsscore + "");
System.out.println ( "Please enter university English scores:");
STU1 [0] = .englishiscore input.nextInt ();
chengjilurujiemianer ();
System.out.println ( "the high number of score of" + STU1 [0] .mathematicsscore + "");
System.out.println ( "College English score of" + STU1 [0] .englishiscore + "");
IF (STU1 [ 0] == .networkscore 0.0)
System.out.println ( "Please enter the computer network results:");
STU1 [0] = .networkscore input.nextInt ();
chengjilurujiemianer ();
System.out.println ( "the high number of score of "+ STU1 [0] .mathematicsscore +" ");
System.out.println (" College English score of "+ STU1 [0] .englishiscore +" ");
System.out.println (" computer network score of "+ STU1 [0] .networkscore + "");
System.out.println ( "Please enter the data structure results:");
STU1 [0] = .databasescore input.nextInt ();
chengjilurujiemianer ();
System.out.println ( " the high number of score of "+ stu1 [0] .mathematicsscore + " ");
System.out.println ( "College English score of" + stu1 [0] .englishiscore + "");
System.out.println ( "Computer Network score of" + STU1 [0] .networkscore + "");
System.out.println ( "Data Structure score of" + STU1 [0] .databasescore + "");
the System.out. println ( "Please enter the software Engineering results:");
STU1 [0] = .softwarescore input.nextInt ();
chengjilurujiemianer ();
System.out.println ( "the high number of score of" + stu1 [0] .mathematicsscore + "" );
System.out.println ( "College English score of" + STU1 [0] .englishiscore + "");
System.out.println ( "computer network score of" + STU1 [0] .networkscore + "");
System. out.println ( "data structure score of" + STU1 [0] .databasescore + "");
System.out.println ( "software Engineering score of" + STU1 [0] .softwarescore + "");
System.out.println ( "the student achievement input is completed, whether or not to submit (the Y-/ N)");
System.out.println("****************************************************************");

sj=jidian(stu1[0].mathematicsscore);
jidian = YJ (STU1 [0] .englishiscore);
JJ = jidian (STU1 [0] .networkscore);
GJ = jidian (STU1 [0] .databasescore);
RJ = jidian (STU1 [0] .softwarescore);
Double PJJ = (stu1 [0] .mathematicsscore * 4 + stu1 [0] .englishiscore * 3 + stu1 [0] .networkscore * 4 + stu1 [0] .databasescore * 3 + stu1 [0] .softwarescore * 2) / 16;
jidian = PJ (PJJ);
}
xuanze ();
BREAK;
Case 2: xiugaichengji ();
I = input.nextInt ();
Switch (I)
{
Case. 1: after System.out.println ( "Please enter edit HIGHER math: ");
STU1 [0] = .mathematicsscore input.nextInt ();
BREAK;
Case 2: System.out.println (" Please enter university English scores revised: ");
STU1 [0] = .englishiscore input.nextInt ();
BREAK;
case 3: System.out.println ( "Please enter the computer network modified score:");
STU1 [0] = .networkscore input.nextInt ();
BREAK;
Case. 4: System.out.println ( "Please enter the edit after the data structure results: ");
STU1 [0] = .databasescore input.nextInt ();
BREAK;
Case. 5: System.out.println (" Please enter the modified software engineering grade: ");
STU1 [0] = input.nextInt .softwarescore ();
BREAK;
}
chengjilurujiemianer ();
System.out.println ( "score of the high number of" + STU1 [0] .mathematicsscore + "");
System.out.println ( "English score "+ stu1 [0] .englishiscore +" ");
System.out.println (" computer network score of "+ stu1 [0] .networkscore +" ");
System.out.println (" data structure score of "+ stu1 [ 0] .databasescore + "");
System.out.println ( "Software engineering achievement as "+ stu1 [0] .softwarescore +" ");
System.out.println ( "The student achievement input is completed, whether or not to submit (the Y-/ N)");
System.out.println ( "******************** **************************** ");
xuanze () ;
BREAK;
Case. 3:


chengjijidian ();
xuanze ();
BREAK;
Case. 4:
tuichujiemian ();
BREAK;



}
}
public static void chengjilurujiemain ()
{
System.out.println ( "*************************************** ************************************************** **** ");
System.out.println (" Shijiazhuang Railway Institute of software Engineering student management system version 2019 ");
System.out.println (" student test scores entry ");
System.out.println (" ************************************************** ************* ");
System.out.println (" enter the student number: ");
System.out.println ( "******************************************* ************************************************************ ");
}
public static void chengjilurujiemianer ()
{
System.out.println (" ************ ************************************************** * ");
System.out.println (" Shijiazhuang Railway Institute of software Engineering student management system version 2019 ");
System.out.println (" student test scores entry ");
System.out.println (" *** ************************************************** ********** ");
System.out.println (" candidates Student ID: "ScoreInformatio.stunumber + +" ");
System.out.println (" candidates name: "+ ScoreInformatio.name +" " );
System.out.println ( "***************************************** ************************************************************ ");

}
public static void chengjijidian()
{
System.out.println ( "******************************************* ********************* ");
System.out.println (" Shijiazhuang Railway Institute of software Engineering student management system version 2019 ");
System.out. println ( "student test scores to calculate grade point interface");
System.out.println ( "*********************************************************** ********************************** ");
System.out.println (" candidates Student ID: "+ + ScoreInformatio.stunumber "");
System.out.println ( "candidates name:" + ScoreInformatio.name + "");
System.out.println ( "1, higher math scores for Grade point:" + SJ + "");
System. out.println ( "2, in achievement Grade point Average:" YJ + + "");
System.out.println ( "3, computer network performance grade point:" + jj + "");
System.out.println ( "4 , GPA data structure results: "+ GJ +" ");
System.out.println ("5, software engineering achievement grade point: "RJ + +" ");
System.out.println (" your grade point average is: "+ PJ +" ");
IF (PJ> = 2)
System.out.println ( "message: You have reached Grade Point graduation requirements!");
The else
System.out.println ( "message: Your Grade Point does not meet the requirements for graduation!");
System.out .println ( "system is returning home page: (the Y / N)");
System.out.println ( "************************************************************ **************************************** ");
}
public static void xiugaichengji ()
{
System.out.println ( "****************************************** *********************** ");
System.out.println (" Shijiazhuang Railway Institute of software Engineering student management system version 2019 ");
system. out.println ( "student test scores input interface");
System.out.println ( "*********************************************************** ************************************ ");
System.out.println (" candidates Student ID: "ScoreInformatio.stunumber + +" ");
the System.out.println ( "candidate name:" + ScoreInformatio.name + "");

}
public static double jidian(double n)
{
double s=0;
if(n<60)
s=0;
else if(n>=60&&n<63.5)
s=1.0;
else if(n>=64&&n<65.9)
s=1.5;
else if(n>=66&&n<67.9)
s=1.7;
else if(n>=68&&n<71.5)
s=2.0;
else if(n>=72&&n<74.5)
s=2.3;
else if(n>=75&&n<77.9)
s=2.7;
else if(n>=78&&n<81.9)
s=3.0;
else if(n>=82&&n<84.5)
s=3.3;
else if(n>=85&&n<89.9)
s=3.7;
else if(n>=90)
s=4.0;
return s;
}
public static void xuanze()
{
String c;
Scanner input=new Scanner(System.in);
c=input.next();
char x=c.charAt(0);
if(x=='Y')
zhujiemian();
else if(x=='N');


}

}

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Guess you like

Origin www.cnblogs.com/zl00/p/11515575.html