- You should create your programs with good programming style and form using proper blank spaces, indentation and braces to make your code easy to read and understand;
- You should create identifiers with sensible names;
- You should make comments to describe your code segments where they are necessary for readers to understand what your code intends to achieve.
- Logical structures and statements are properly used for specific purposes.
- Read the assignment specification carefully, and make sure that you follow whatever directed in this assignment. In every assignment that you will submit in this subject, you must put the following information in the header of your program:
/*
My name:
My student number: My course code: CSIT121 My email address:
Assignment number: 1
-*/
Objectives
This assignment requires you to write a program in Java that help a student to enrol into the Bachelor of Computer Science course, including the core subjects enrolment, the selecting of a major and the elective subjects.
Background
The Bachelor of Compute Science course contains three parts, i.e., the core subjects, the majors and the elective subjects. In order to complete the course, students shall complete at least 144 credit points.
- All students shall complete 15 core subjects, i.e., 96 cp in total.
- All students shall complete a major with four or five subjects, i.e., 24/30 cp in total. The course contains five majors and each student can only select one major. The five majors are Big Data, Cyber Security, Digital Systems Security, Game and Mobile Development, and Software Engineering. The core subjects of each major are displayed in the following snapshots.
(It is assumed that all five subjects are compulsory for the Game and Mobile Development Major)
- All students shall enrol 4~5 elective subjects to make up 144 credit points. (Students are allowed to enrol more than 144 credit points). The elective subjects are the collection of subjects from all five majors.
You are required to design, implement and test a course enrolment system to enrol one student into the Bachelor of Computer Science course by using Java. The system shall contain five classes, i.e., the Student class, the Subject class, the Major class, the Course class, and the Enrolment class (the primary class). The basic requirements of each class are as follows:
- Student class
The purpose of Student class is to maintain the personal information of a student, i.e., the student name, the student number, the gender, and the date of birth.
- Subject class
The purpose of Subject class is to maintain a subjects information, i.e., the subject name, the subject code, the credit point of the subject.
- Major class
The purpose of Major class is to maintain the information of a major, i.e., the major name, and all major subjects.
- Course class
The purpose of Course class is to maintain the information of a course (Bachelor of Computer Science), i.e., the course name, the core subjects of the course, the majors of the course, the elective subjects of the course, and the minimal credit points requirement of the course.
- Enrolment class (primary class)
The purpose of Enrolment class is to help a student to enrol into the Bachelor of Computer Science course with the following steps in the main() method. i) to display the entire course structure to the student; ii) to ask the student to input the personal information (by using the Scanner); iii) to automatically enrol the student to all core subjects;
- to ask the student to select a major and automatically enrol the student to all subjects of the major;
- to ask the student to select sufficient elective subjects for reaching the minimal credit points requirement of the course, i.e., 144 credit points; vi) once the student enrols sufficient subjects to make up at least 144 credit points, the enrolment is completed. vii) to display the students final enrolment record.
Note: You can use the hardcode to create the course structure for the Bachelor of Computer Science. You can also assume the users inputs are always correct. See an example to create the course structure with the hardcode in the main() method.
See the snapshots of an example for the program testing. Your program must have the exact same outputs for the same inputs. The users inputs are highlighted by blue colour, my explanations (not the inputs or outputs) are highlighted by green colour. The watermark is used to prevent the snapshots are used in your solution. You must capture the snapshots of your own programs outputs.
Big Data Major Cores:
Tasks
Task 1 : Complete the program design by using the UML class diagrams. The class diagrams shall
- contains at least the five classes mentioned above;
- contains class name, fields and methods definitions for each class;
- use correct and sufficient UML notations;
- clearly specify the associations between classes;
- clearly specify the multiplicities for both sides of the associations.
Task 2 (5 marks): Implement the system according to the UML class diagrams. The program shall
- be consistent with the UML class diagrams;
- follow the conventions for naming all classes, variables, and methods;
- provide sufficient comments;
- use proper blank spaces, indentation and braces to make your code easy to read and understand;
- follow the specified steps in Enrolment class to enrol the student into the Bachelor of Computer Science course;
- be able to automatically calculate the remaining elective subject number for the minimal credit points requirement.
Task 3 : Compilation and test. You should compile and test your program by using two different cases. The first testing case must use the exact same inputs in the example. The second testing case must choose different majors and elective subjects. Please carefully compile and test your program and make sure your program can pass the compile by using javac command. Please do not define the package in your program (a special alert for students who use IDE to complete the assignment).
Reviews
There are no reviews yet.