Answered step by step
Verified Expert Solution
Question
1 Approved Answer
JAVA need ASAP.. thanks in advance QUESTION 1 Kolej Universiti Cerdik Bijaksana offers two elective courses that can be enrolled by many students from many
JAVA
need ASAP.. thanks in advance
QUESTION 1 Kolej Universiti Cerdik Bijaksana offers two elective courses that can be enrolled by many students from many programs. The following text file, enrollment.txt contains the enrollment records of students for courses CTU553 and CTU551: moment-Nomad File Edit Format View Help 2017412386; MUHAD ALIF BIN RAMLEE;C522e;CTUS53 2017427932, SITI LAILA FARHANA BINTI HISHAM,C5240,CTU553 2018695566;AMTR THAN BIN KAMALUDTN;CS232;CTU551 2019294224;NUR SYAHRINA BINTI GHAZALT;CS232;CTU551 2019328731;ZAKI HARI BIN MOHD NIZAM:C8220;CTU553 2019335369;MUHAUD HARITH BIN NOOR AFFANDEE;CS223;CTU553 2019635356;AMIN BIN ZAMSANIRANI;CS226;CTUSS 2019820038;AIN NAMIN BINTI JAMALUDIN;CS238;CTUS51 2028462348; INTAN SORFINA BINTI MOHD FADHIL;C5225,CTU553 2020496204, NUR HIDAYAH BINTI ISHAK;C5224;CTU551 2020615326, NURAIN SYAMIMI NADIA BINTI MOHD NASZERT,C5230;CTU553 2020834416;PUH ZULFADLEY ADLI BIN AHMAD PAIZOL;C5230;CTU551 2028859198; NURAIN NATASYA BINTI MUHAMMAD NASIR;CS221;CTU553 2028896796; MOHANSO EUSOFF DANIEL BIN MOHAMAD FAIZAL;CS230;CTUSS3 2028898388; MUHAMO SAIFUDDIN BIN IDRIS SHAZALI;C5221;CTUSS3 2028968723; FARAH DIYANA BINTI MOHD FADZIR;CS230, CU553 2028988441; UTASHA IRINA BINTI KHAIRUL ANNUAR,C5231;CTU551 2020988781;NUR ALYA MASRIN BINTI MOOIN;C5223;CTU553 2017412124;MUHAMAD SYAFI HAKIM BIN MOHD ZUHAIRT;CS223;CTU551 2017412136;AMISA ATIKAH BINTI MOHD FADZIL;CS230;CTUS53 2017412154; NURUL FATIN AMALIN BINTI SHAHBUDIN;CS230;CTUSSI 2017412298, NAZRIN AFZAL BIN MOHD BASIR SELVAM;C5224,CTUS51 In tot 100 winds LITEE Ln 1. Colt 100% Windows (CRLF) UTF-8 Assume the text file consists of thousands of student records. The attributes for each record are student ID, student name, program and course. The following information is about class Enroll: Class: Enroll Attributes: String studID; String studName; String program; String course; Methods: l/default constructor ormal constructor //setter Ilgetters boolean isCTU551 () //returns true if the student register CTU551 toString() Write a complete JAVA program to perform the following tasks: a) Read the records from file enrollment.txt, one by one and store it in an Enroll object named enrolli. b) Count and display the number of students who register CTU551. c) Store the student ID and student name of CS240 students who register CTU553 into an output file named CS 240_CTU553.txt. d) Write any ONE exception handling operations to deal with the file input-output errors. (15 marks)Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started