
急!程序编程设计实践作业,高手们帮帮忙!
四六级考试成绩管理【问题描述】利用已学知识完成“四六级考试成绩管理系统”。【基本功能】(1)首先自己设计好数据结构及算法,将学生成绩信息包括学生姓名、准考证号码、学校、考...
四六级考试成绩管理
【问题描述】
利用已学知识完成“四六级考试成绩管理系统”。
【基本功能】
(1) 首先自己设计好数据结构及算法,将学生成绩信息包括学生姓名、准考证号码、学校、考试级别、选考语种、成绩等用考虑定义一个类来存放,全面考虑如何进行综合管理功能。
(2) 对学生成绩信息包括学生姓名、准考证号码、学校、考试级别、选考语种、成绩的增添、删除、修改功能。
(3) 统计功能:按照考试级别、成绩档次、选考语言、学校对成绩进行分类统计。
(4) 按照准考证号码、姓名查询学生信息,对于同名现象进行提示。
(5) 以添加、删除、修改、查询、统计等管理功能来演示该系统,在基本功能实现的基础上,可考虑增加一些管理选项,如:分类排序等。
(6) 界面友好,可操作性强,设计一个菜单让用户选择管理功能,利用循环结构使得一次运行程序可对多项管理。
我们学的是JAVA 所以最好 是java的 谢谢高手们咯 展开
【问题描述】
利用已学知识完成“四六级考试成绩管理系统”。
【基本功能】
(1) 首先自己设计好数据结构及算法,将学生成绩信息包括学生姓名、准考证号码、学校、考试级别、选考语种、成绩等用考虑定义一个类来存放,全面考虑如何进行综合管理功能。
(2) 对学生成绩信息包括学生姓名、准考证号码、学校、考试级别、选考语种、成绩的增添、删除、修改功能。
(3) 统计功能:按照考试级别、成绩档次、选考语言、学校对成绩进行分类统计。
(4) 按照准考证号码、姓名查询学生信息,对于同名现象进行提示。
(5) 以添加、删除、修改、查询、统计等管理功能来演示该系统,在基本功能实现的基础上,可考虑增加一些管理选项,如:分类排序等。
(6) 界面友好,可操作性强,设计一个菜单让用户选择管理功能,利用循环结构使得一次运行程序可对多项管理。
我们学的是JAVA 所以最好 是java的 谢谢高手们咯 展开
2个回答
2011-06-16
展开全部
希望能对你有所帮助
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
public class CardLayoutDemo extends JFrame implements ActionListener
{
public static final int WIDTH = 300;
public static final int HEIGHT = 200;
private CardLayout dealer;
private JPanel deckPanel;
public CardLayoutDemo( )
{
setSize(WIDTH, HEIGHT);
addWindowListener(new WindowDestroyer( ));
setTitle("CardLayout Demonstration");
Container contentPane = getContentPane( );
contentPane.setLayout(new BorderLayout( ));
deckPanel = new JPanel( );
dealer = new CardLayout( );
deckPanel.setLayout(dealer);
JPanel startCardPanel = new JPanel( );
startCardPanel.setLayout(new FlowLayout( ));
startCardPanel.setBackground(Color.LIGHT_GRAY);
JLabel startLabel = new JLabel("Hello");
startCardPanel.add(startLabel);
deckPanel.add("start", startCardPanel);
JPanel greenCardPanel = new JPanel( );
greenCardPanel.setLayout(new FlowLayout( ));
greenCardPanel.setBackground(Color.GREEN);
JLabel goLabel = new JLabel("Go");
greenCardPanel.add(goLabel);
deckPanel.add("green", greenCardPanel);
JPanel redCardPanel = new JPanel( );
redCardPanel.setLayout(new FlowLayout( ));
redCardPanel.setBackground(Color.RED);
JLabel stopLabel = new JLabel("Stop");
redCardPanel.add(stopLabel);
deckPanel.add("red", redCardPanel);
contentPane.add(deckPanel, BorderLayout.CENTER);
JPanel buttonPanel = new JPanel( );
buttonPanel.setBackground(Color.WHITE);
buttonPanel.setLayout(new FlowLayout( ));
JButton stopButton = new JButton("Red");
stopButton.addActionListener(this);
buttonPanel.add(stopButton);
JButton goButton = new JButton("Green");
goButton.addActionListener(this);
buttonPanel.add(goButton);
JButton resetButton = new JButton("Reset");
resetButton.addActionListener(this);
buttonPanel.add(resetButton);
contentPane.add(buttonPanel, BorderLayout.SOUTH);
dealer.first(deckPanel);//Optional
}
public void actionPerformed(ActionEvent e)
{
String actionCommand = e.getActionCommand( );
if (actionCommand.equals("Red"))
dealer.show(deckPanel, "red");
else if (actionCommand.equals("Green"))
dealer.show(deckPanel, "green");
else if (actionCommand.equals("Reset"))
dealer.show(deckPanel, "start");
else
System.out.println("Error in CardLayout Demo.");
}
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
public class CardLayoutDemo extends JFrame implements ActionListener
{
public static final int WIDTH = 300;
public static final int HEIGHT = 200;
private CardLayout dealer;
private JPanel deckPanel;
public CardLayoutDemo( )
{
setSize(WIDTH, HEIGHT);
addWindowListener(new WindowDestroyer( ));
setTitle("CardLayout Demonstration");
Container contentPane = getContentPane( );
contentPane.setLayout(new BorderLayout( ));
deckPanel = new JPanel( );
dealer = new CardLayout( );
deckPanel.setLayout(dealer);
JPanel startCardPanel = new JPanel( );
startCardPanel.setLayout(new FlowLayout( ));
startCardPanel.setBackground(Color.LIGHT_GRAY);
JLabel startLabel = new JLabel("Hello");
startCardPanel.add(startLabel);
deckPanel.add("start", startCardPanel);
JPanel greenCardPanel = new JPanel( );
greenCardPanel.setLayout(new FlowLayout( ));
greenCardPanel.setBackground(Color.GREEN);
JLabel goLabel = new JLabel("Go");
greenCardPanel.add(goLabel);
deckPanel.add("green", greenCardPanel);
JPanel redCardPanel = new JPanel( );
redCardPanel.setLayout(new FlowLayout( ));
redCardPanel.setBackground(Color.RED);
JLabel stopLabel = new JLabel("Stop");
redCardPanel.add(stopLabel);
deckPanel.add("red", redCardPanel);
contentPane.add(deckPanel, BorderLayout.CENTER);
JPanel buttonPanel = new JPanel( );
buttonPanel.setBackground(Color.WHITE);
buttonPanel.setLayout(new FlowLayout( ));
JButton stopButton = new JButton("Red");
stopButton.addActionListener(this);
buttonPanel.add(stopButton);
JButton goButton = new JButton("Green");
goButton.addActionListener(this);
buttonPanel.add(goButton);
JButton resetButton = new JButton("Reset");
resetButton.addActionListener(this);
buttonPanel.add(resetButton);
contentPane.add(buttonPanel, BorderLayout.SOUTH);
dealer.first(deckPanel);//Optional
}
public void actionPerformed(ActionEvent e)
{
String actionCommand = e.getActionCommand( );
if (actionCommand.equals("Red"))
dealer.show(deckPanel, "red");
else if (actionCommand.equals("Green"))
dealer.show(deckPanel, "green");
else if (actionCommand.equals("Reset"))
dealer.show(deckPanel, "start");
else
System.out.println("Error in CardLayout Demo.");
}
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询