CSC 126 GP Report
CSC 126 GP Report
PROJECT REPORT
(STUDENTS FINE SYSTEM)
TEAM MEMBERS :
1.MUHAMMAD ANIQ SYAMIL BIN MOHD AZMAN (2023889366)
2. ABU DZAR RAMZANIZAM (2023865136)
3. MUHAMMAD AIMAN BIN MOHD ZIN (2023831356)
4. ADAM HAIKAL BIN MOHD RUDZI (2023871028)
: RCDCS1101E
1
TABLE OF CONTENTS
2
1.0 PROJECT SUMMARY
UiTM Student Fine Program is a system built to help UiTM staffs keying in the information of the students
fault and students can check and pay for their fine without going to the HEP offices.Before this students have
to write their names and list all the fault that they did within the UiTM campus rules in a piece of paper that
are easily lost or destroyed. This can cause dishonest and faulty behavior to culprits that can destroy
evidence of what have they done. The UiTM Student Fine Program stores information for the Uitm staffs to
key in the fine that students receive. The program will keep all the data in the students ID with that students
need to login and check their fined to make sure that they pay their fine. Some information must be gathered
by the program to initialize the fine of the students by logging in for the program to run. In the final stages of
calculation, the program will display ID, students fault, amount payable.
-Developing a system that stores all the data of students that disobeyed the UiTM campus law.
-Developing a new revolutionary system that can be monitored and saved in a computerized system
3
3.0 INPUT/PROCESS/OUTOUT
Specified Process
First of all user will need to choose whether to start the program or not,
After that, user will need to register to ensure it’s not a robot.
User will register their name ,uitm ID and create a password
Function (main)
• “Please enter your uitm id.
• “Please enter your password”
After the registration complete, the main operation will begin with determine if string compare registered uitm id and
registered uitm is equal to login uitm id and login password.
Function (menu)
• “Please select SRD , Hostel , Vehicles “
• If “SRD”
- Self appearance(using array)
• If “Hostel “(using array)
- Smoking
- Forbidden item
- Dirty room
- Vandalism
- Disturbing
- Sleep in a restricted area
• If ” Vehicles “(using array)
- Not registered vehicles
- Exceeding the speed limit
- Not wearing helmet
- Vehicles impounded
- Bring vehicles illegally
4
Calculation
• Total fine = fine chosen by student.
Repeatition
• “Do you want to enter another fault ?
5
Input Name
. Uitm Id
Password
Entered uitm id
Entered password
Type of fault
Fault Code
Respond
Output
Name of fault,
total fine
type of fault
6
4.0 FLOWCHART
7
8
9
10
11
5.0 PSEUDOCODE
START
Procedure srd_fault();
Procedure hostel_fault();
Procedure vehicle_fault();
Procedure Main():
String name, password, entered_password, id, enteredID, res
Integer ic, type
Switch type:
Case 1: srd_fault()
Case 2: hostel_fault()
Case 3: vehicle_fault()
Default: Output("\tInvalid Type Fault....")
12
Output("\tPlease enter 'y' to continue the system...")
Input(res)
Until res is not equal to 'y'
Else:
Output("\tInvalid ID or Password")
Output("\tPlease Save the statement and bring it to HEP Department for settlement fine...")
Output("\tThank you for using Fine UITM Portal....")
SystemPause()
End Procedure
module srd_fault():
// Define SRD fault information
Array code_fault[1 to 3] = {1, 2, 3}
Array name_fault[1 to 3][1 to 50] = {
"Does not Meet SRD during academic session",
"Long Hair, Mustache, Beard and Colored Hair",
"Forbidden Accessories"
}
Array fine_fault[1 to 3] = {50, 30, 20}
Output("\n\t+------+------------+-----------+")
Output("\t| Code | Fault | Fine(RM) |")
Output("\t+------+-------------+----------+")
For i = 1 to 3:
Output("\t| " + code_fault[i] + "| " + LeftAligned(name_fault[i], 11) + "| " + LeftAligned(fine_fault[i], 7) + " |")
Procedure hostel_fault():
// Define Hostel fault information
Array code_fault[1 to 6] = {1, 2, 3, 4, 5, 6}
Array name_fault[1 to 6][1 to 50] = {"Smoking", "Forbidden Item", "Dirty Room", "Vandalism", "Disturbing Peace",
"Sleeping Restricted Area"}
Array fine_fault[1 to 6] = {50, 50, 30, 70, 30, 30}
Output("\n\t+------+------------+-----------+")
Output("\t| Code | Fault | Fine(RM) |")
Output("\t+------+-------------+----------+")
For i = 1 to 6:
Output("\t| " + code_fault[i] + "| " + LeftAligned(name_fault[i], 11) + "| " + LeftAligned(fine_fault[i], 7) + " |")
Procedure vehicle_fault():
// Define Vehicle fault information
Array code_fault[1 to 5] = {1, 2, 3, 4, 5}
Array name_fault[1 to 5][1 to 50] = {
"Vehicle not registered",
"Exceeding speed limit",
"Not wearing helmet",
"Vehicle impounded",
"Illegal Vehicle"
}
Array fine_fault[1 to 5] = {70, 50, 30, 100, 200}
Output("\n\t+------+------------+-----------+")
Output("\t| Code | Fault | Fine(RM) |")
Output("\t+------+-------------+----------+")
For i = 1 to 5:
Output("\t| " + code_fault[i] + "| " + LeftAligned(name_fault[i], 11) + "| " + LeftAligned(fine_fault[i], 7) + " |")
15
// Get user input for fault code
Output("\tType Code: ")
Input(code)
16
6.0 SOURCE CODE
#include<iostream>
#include<iomanip>
#include<string.h>
using namespace std;
void srd_fault();
void hostel_fault();
void vehicle_fault();
int main()
{
char name[30],password[100],entered_password[100],id[11],enteredID[11],res;
int ic,type;
}
cout<<"\tPlease enter y to continue the system..."<<endl;
cin>>res;
}while (res=='y') ;
}
else// If ID and password user !=0
cout<<"\tInvalid Id or Password"<<endl;
cout<<"\tPlease Save the statement and bring it to HEP Deparment for settlement fine..."<<endl;
cout<<"\tThank you for using Fine UITM Portal...."<<endl;
system("Pause");
}
int code;
int fine;
string name;
18
cout << "\t================" <<endl;
cout << "\tSRD List Fault" <<endl;
cout << "\t================" <<endl;
cout <<endl;
cout << "\t+------+------------+-----------+" <<endl;
cout << "\t| Code | Fault | Fine(RM) |" <<endl;
cout << "\t+------+-------------+----------+" <<endl;
if (code == 1)
{
name = name_fault[0];
fine = fine_fault[0];
}
else if (code == 2)
{
name = name_fault[1];
fine = fine_fault[1];
}
else if (code == 3)
{
name = name_fault[2];
fine = fine_fault[2];
}
int code;
int fine;
string name;
cout <<endl;
cout << "\t+------+------------+-----------+" <<endl;
cout << "\t| Code | Fault | Fine(RM) |" <<endl;
cout << "\t+------+-------------+----------+" <<endl;
if (code == 1)
{
name = name_fault[0];
fine = fine_fault[0];
}
else if (code == 2)
{
20
name = name_fault[1];
fine = fine_fault[1];
}
else if (code == 3)
{
name = name_fault[2];
fine = fine_fault[2];
}
else if ( code == 5)
{
name = name_fault[4];
fine = fine_fault[4];
}
else if ( code == 6)
{
name = name_fault[5];
fine = fine_fault[5];
}
int code;
int fine;
string name;
cout <<endl;
cout << "\t+------+------------+-----------+" <<endl;
cout << "\t| Code | Fault | Fine(RM) |" <<endl;
cout << "\t+------+-------------+----------+" <<endl;
if (code == 1)
{
name = name_fault[0];
fine = fine_fault[0];
}
else if (code == 2)
{
name = name_fault[1];
fine = fine_fault[1];
}
else if (code == 3)
{
name = name_fault[2];
fine = fine_fault[2];
}
else if ( code == 5)
{
name = name_fault[4];
22
fine = fine_fault[4];
}
23
6.0 SAMPLES OF OUTPUT
Login page:
24
25
26
Login invalid (repeatation)
27
Login pick
28
Login with receipt
29
8.0 DISCUSSION
2.Menu-Driven System:
-Enhance the user interface by providing more detailed information about each fault category.
-Implement a clearer navigation system to guide users through the different options.
3.Fine Categories:
-Use a data structure like a struct or class to better organize information about each fault category.
-Consider adding a description field for each fault category to provide more context to users.
5.User Interaction:
-Integrate a database to store user information and fault records for better scalability.
-Implement a feature for users to view their fine history and payment status.
7.Error Handling:
-Enhance error handling by providing specific error messages for different scenarios.
-Implement a system to temporarily lock accounts after multiple failed login attempts to prevent brute force attacks.
30
9.0 CONCLUSION
The UiTM fine system source code demonstrates a functional approach to categorizing and managing student faults
related to self-appearance, hostel, and vehicles. While the code provides a foundation for a fine system, several
areas can be enhanced, such as security measures, user interaction, and error handling. Integrating encryption,
improving the user interface, and implementing a database for data storage are recommended for a more robust
system.
31