You are given a text file named college_application.txt which contains a list of applications for residential...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
You are given a text file named college_application.txt which contains a list of applications for residential colleges at UITM Shah Alam. The data is comprised of the application submission date, student id, name, faculty, semester, and home address. The home address consists of the street name, postcode, city, and state separated by a comma. 13/01/2022;20212897; Male; Imaad bin Jaad; FPA; 8; Jalan Perajurit, 42000, Pelabuhan Klang, Selangor 22/01/2022;20209621;Male; Zaki bin Hamza; FSPU; 6; Kubang Buaya, 12300, Butterworth, Pulau Pinang 26/01/2022;20213740; Female; as Ayu binti Selamat; FSPU; 8; Jalan Ru (1-3), 11500, Ayer Itam, Pulau Pinang 13/02/2022;20218909; Female; Alidia Bernardet; FSG;6; Jalan Padang Lalang, 84900, Tangkak, Johor 21/01/2022;20211475;Male; Deraman bin Mamat;FSKM; 3; Taman Kawan, 35500, Bidor, Perak 06/01/2022;20224614; Female; Haaniya binti Sufyaan; FSPU; 3; Taman Berkat (1 & 2),84000, Muar, Johor 02/02/2022;20212993; Male; Deraman bin Kamis;FKA; 3; Kampung Batu Bekarang, 98700, Limbang, Sarawak 13/02/2022;20219484;Male;Nawfal bin Wajdi;FKE; 8; Perkampungan Pandan Jaya, 26070, Kuantan, Pahang 02/01/2022;20218979; Female; Taqiyya binti Zainuddeen; FPA; 7; Jalan Permata 7/1,40000, Shah Alam, Selangor 04/01/2022;20215384; Male; Shandie Mariyushkin; FPA; 1; Kampung Baru Kuala Sungai Baru, 78200, Kuala Sungai Baru, Melaka 03/01/2022;20207854; Female; Aneesa binti Muhyddeen; FKE;5; Taman Mesra Indah, 8100, Bedong, Kedah 05/02/2022:20212823; Male; Jusoh bin Daud; FKE; 7; Lorong Orkid, 88300, Kota Kinabalu, Sabah 25/01/2022;20217497; Female; Guglielma Bartholin; FPA; 2; Astaka Heights, 56100, Kuala Lumpur, Kuala Lumpur Figure 1: college_application.txt Write a complete Java program using File I/O operation that can perform the following tasks: a) Read all records from the text file named college_application. txt in Figure 1. successful residential college applications into b) Write successful applications.txt. Since the number of rooms is limited, only students that meet any of the following criteria will be accepted: Students that are in semester 5 and above Students from Sabah or Sarawak A sample of successful_applications.txt is shown in Figure 2. 13/01/2022;20212897; Male; Imaad bin Jaad; FPA; 8; Jalan Perajurit, 42000, Pelabuhan Klang, Selangor 22/01/2022;20209621;Male; Zaki bin Hamza; FSPU; 6; Kubang Buaya, 12300, Butterworth, Pulau Pinang 26/01/2022;20213740; Female; as Ayu binti Selamat;FSPU; 8; Jalan Ru (1 3), 11500, Ayer Itam, Pulau Pinang 13/02/2022;20218909; Female; Alidia Bernardet;FSG; 6; Jalan Padang Lalang, 84900, Tangkak, Johor 02/02/2022;20212993; Male; Deraman bin Kamis;FKA; 3; Kampung Batu Bekarang, 98700, Limbang, Sarawak 13/02/2022;20219484; Male;Nawfal bin Wajdi;FKE; 8; Perkampungan Pandan Jaya, 26070, Kuantan, Pahang | c) Applications from students that do not meet any of the criteria in b) but the application submission date is in January will be placed on the waiting list. Write their information to waiting list.txt as shown in Figure 3. 21/01/2022;20211475; Male; Deraman bin Mamat;FSKM; 3; Taman Kawan, 35500, Bidor, Perak 06/01/2022;20224614; Female; Haaniya binti Sufyaan; FSPU; 3; Taman Berkat (1 & 2),84000 Muar, Johor 04/01/2022;20215384; Male; Shandie Mariyushkin; FPA; 1; Kampung Baru Kuala Sungai Baru, 78200, Kuala Sungai Baru, Melaka 25/01/2022;20217497; Female; Guglielma Bartholin; FPA; 2; Astaka Heights, 56100, Kuala Lumpur, Kuala Lumpur 02/01/2022;20217082; Female; Susana Hessle; FKM; 2; Sira Kulim, 33300, Gerik, Perak 20/01/2022;20201382; Female; Atiyya binti Humaid; FSPU;4; Jalan Panji Alam,21100, Kuala Terengganu, Terengganu Figure 3: waiting_list.txt d) Display on the screen the number of successful applications and the number of applications on the waiting list. e) Close all file streams in use. f) Apply exception handling mechanism in the program. You are given a text file named college_application.txt which contains a list of applications for residential colleges at UITM Shah Alam. The data is comprised of the application submission date, student id, name, faculty, semester, and home address. The home address consists of the street name, postcode, city, and state separated by a comma. 13/01/2022;20212897; Male; Imaad bin Jaad; FPA; 8; Jalan Perajurit, 42000, Pelabuhan Klang, Selangor 22/01/2022;20209621;Male; Zaki bin Hamza; FSPU; 6; Kubang Buaya, 12300, Butterworth, Pulau Pinang 26/01/2022;20213740; Female; as Ayu binti Selamat; FSPU; 8; Jalan Ru (1-3), 11500, Ayer Itam, Pulau Pinang 13/02/2022;20218909; Female; Alidia Bernardet; FSG;6; Jalan Padang Lalang, 84900, Tangkak, Johor 21/01/2022;20211475;Male; Deraman bin Mamat;FSKM; 3; Taman Kawan, 35500, Bidor, Perak 06/01/2022;20224614; Female; Haaniya binti Sufyaan; FSPU; 3; Taman Berkat (1 & 2),84000, Muar, Johor 02/02/2022;20212993; Male; Deraman bin Kamis;FKA; 3; Kampung Batu Bekarang, 98700, Limbang, Sarawak 13/02/2022;20219484;Male;Nawfal bin Wajdi;FKE; 8; Perkampungan Pandan Jaya, 26070, Kuantan, Pahang 02/01/2022;20218979; Female; Taqiyya binti Zainuddeen; FPA; 7; Jalan Permata 7/1,40000, Shah Alam, Selangor 04/01/2022;20215384; Male; Shandie Mariyushkin; FPA; 1; Kampung Baru Kuala Sungai Baru, 78200, Kuala Sungai Baru, Melaka 03/01/2022;20207854; Female; Aneesa binti Muhyddeen; FKE;5; Taman Mesra Indah, 8100, Bedong, Kedah 05/02/2022:20212823; Male; Jusoh bin Daud; FKE; 7; Lorong Orkid, 88300, Kota Kinabalu, Sabah 25/01/2022;20217497; Female; Guglielma Bartholin; FPA; 2; Astaka Heights, 56100, Kuala Lumpur, Kuala Lumpur Figure 1: college_application.txt Write a complete Java program using File I/O operation that can perform the following tasks: a) Read all records from the text file named college_application. txt in Figure 1. successful residential college applications into b) Write successful applications.txt. Since the number of rooms is limited, only students that meet any of the following criteria will be accepted: Students that are in semester 5 and above Students from Sabah or Sarawak A sample of successful_applications.txt is shown in Figure 2. 13/01/2022;20212897; Male; Imaad bin Jaad; FPA; 8; Jalan Perajurit, 42000, Pelabuhan Klang, Selangor 22/01/2022;20209621;Male; Zaki bin Hamza; FSPU; 6; Kubang Buaya, 12300, Butterworth, Pulau Pinang 26/01/2022;20213740; Female; as Ayu binti Selamat;FSPU; 8; Jalan Ru (1 3), 11500, Ayer Itam, Pulau Pinang 13/02/2022;20218909; Female; Alidia Bernardet;FSG; 6; Jalan Padang Lalang, 84900, Tangkak, Johor 02/02/2022;20212993; Male; Deraman bin Kamis;FKA; 3; Kampung Batu Bekarang, 98700, Limbang, Sarawak 13/02/2022;20219484; Male;Nawfal bin Wajdi;FKE; 8; Perkampungan Pandan Jaya, 26070, Kuantan, Pahang | You are given a text file named college_application.txt which contains a list of applications for residential colleges at UITM Shah Alam. The data is comprised of the application submission date, student id, name, faculty, semester, and home address. The home address consists of the street name, postcode, city, and state separated by a comma. 13/01/2022;20212897; Male; Imaad bin Jaad; FPA; 8; Jalan Perajurit, 42000, Pelabuhan Klang, Selangor 22/01/2022;20209621;Male; Zaki bin Hamza; FSPU; 6; Kubang Buaya, 12300, Butterworth, Pulau Pinang 26/01/2022;20213740; Female; as Ayu binti Selamat; FSPU; 8; Jalan Ru (1-3), 11500, Ayer Itam, Pulau Pinang 13/02/2022;20218909; Female; Alidia Bernardet; FSG;6; Jalan Padang Lalang, 84900, Tangkak, Johor 21/01/2022;20211475;Male; Deraman bin Mamat;FSKM; 3; Taman Kawan, 35500, Bidor, Perak 06/01/2022;20224614; Female; Haaniya binti Sufyaan; FSPU; 3; Taman Berkat (1 & 2),84000, Muar, Johor 02/02/2022;20212993; Male; Deraman bin Kamis;FKA; 3; Kampung Batu Bekarang, 98700, Limbang, Sarawak 13/02/2022;20219484;Male;Nawfal bin Wajdi;FKE; 8; Perkampungan Pandan Jaya, 26070, Kuantan, Pahang 02/01/2022;20218979; Female; Taqiyya binti Zainuddeen; FPA; 7; Jalan Permata 7/1,40000, Shah Alam, Selangor 04/01/2022;20215384; Male; Shandie Mariyushkin; FPA; 1; Kampung Baru Kuala Sungai Baru, 78200, Kuala Sungai Baru, Melaka 03/01/2022;20207854; Female; Aneesa binti Muhyddeen; FKE;5; Taman Mesra Indah, 8100, Bedong, Kedah 05/02/2022:20212823; Male; Jusoh bin Daud; FKE; 7; Lorong Orkid, 88300, Kota Kinabalu, Sabah 25/01/2022;20217497; Female; Guglielma Bartholin; FPA; 2; Astaka Heights, 56100, Kuala Lumpur, Kuala Lumpur Figure 1: college_application.txt Write a complete Java program using File I/O operation that can perform the following tasks: a) Read all records from the text file named college_application. txt in Figure 1. successful residential college applications into b) Write successful applications.txt. Since the number of rooms is limited, only students that meet any of the following criteria will be accepted: Students that are in semester 5 and above Students from Sabah or Sarawak A sample of successful_applications.txt is shown in Figure 2. 13/01/2022;20212897; Male; Imaad bin Jaad; FPA; 8; Jalan Perajurit, 42000, Pelabuhan Klang, Selangor 22/01/2022;20209621;Male; Zaki bin Hamza; FSPU; 6; Kubang Buaya, 12300, Butterworth, Pulau Pinang 26/01/2022;20213740; Female; as Ayu binti Selamat;FSPU; 8; Jalan Ru (1 3), 11500, Ayer Itam, Pulau Pinang 13/02/2022;20218909; Female; Alidia Bernardet;FSG; 6; Jalan Padang Lalang, 84900, Tangkak, Johor 02/02/2022;20212993; Male; Deraman bin Kamis;FKA; 3; Kampung Batu Bekarang, 98700, Limbang, Sarawak 13/02/2022;20219484; Male;Nawfal bin Wajdi;FKE; 8; Perkampungan Pandan Jaya, 26070, Kuantan, Pahang | c) Applications from students that do not meet any of the criteria in b) but the application submission date is in January will be placed on the waiting list. Write their information to waiting list.txt as shown in Figure 3. 21/01/2022;20211475; Male; Deraman bin Mamat;FSKM; 3; Taman Kawan, 35500, Bidor, Perak 06/01/2022;20224614; Female; Haaniya binti Sufyaan; FSPU; 3; Taman Berkat (1 & 2),84000 Muar, Johor 04/01/2022;20215384; Male; Shandie Mariyushkin; FPA; 1; Kampung Baru Kuala Sungai Baru, 78200, Kuala Sungai Baru, Melaka 25/01/2022;20217497; Female; Guglielma Bartholin; FPA; 2; Astaka Heights, 56100, Kuala Lumpur, Kuala Lumpur 02/01/2022;20217082; Female; Susana Hessle; FKM; 2; Sira Kulim, 33300, Gerik, Perak 20/01/2022;20201382; Female; Atiyya binti Humaid; FSPU;4; Jalan Panji Alam,21100, Kuala Terengganu, Terengganu Figure 3: waiting_list.txt d) Display on the screen the number of successful applications and the number of applications on the waiting list. e) Close all file streams in use. f) Apply exception handling mechanism in the program. c) Applications from students that do not meet any of the criteria in b) but the application submission date is in January will be placed on the waiting list. Write their information to waiting list.txt as shown in Figure 3. 21/01/2022;20211475; Male; Deraman bin Mamat;FSKM; 3; Taman Kawan, 35500, Bidor, Perak 06/01/2022;20224614; Female; Haaniya binti Sufyaan; FSPU; 3; Taman Berkat (1 & 2),84000 Muar, Johor 04/01/2022;20215384; Male; Shandie Mariyushkin; FPA; 1; Kampung Baru Kuala Sungai Baru, 78200, Kuala Sungai Baru, Melaka 25/01/2022;20217497; Female; Guglielma Bartholin; FPA; 2; Astaka Heights, 56100, Kuala Lumpur, Kuala Lumpur 02/01/2022;20217082; Female; Susana Hessle; FKM; 2; Sira Kulim, 33300, Gerik, Perak 20/01/2022;20201382; Female; Atiyya binti Humaid; FSPU;4; Jalan Panji Alam,21100, Kuala Terengganu, Terengganu Figure 3: waiting_list.txt d) Display on the screen the number of successful applications and the number of applications on the waiting list. e) Close all file streams in use. f) Apply exception handling mechanism in the program.
Expert Answer:
Related Book For
Java An Introduction To Problem Solving And Programming
ISBN: 9780134462035
8th Edition
Authors: Walter Savitch
Posted Date:
Students also viewed these programming questions
-
can someone solve this Modern workstations typically have memory systems that incorporate two or three levels of caching. Explain why they are designed like this. [4 marks] In order to investigate...
-
Markku Antero Oy produces perfume. To make this perfume, Markku Antero uses three different types of fluid. Tartarus, Erebus and Uranus are used in standard proportions of -14-0, -3- 10 and -3- 10,...
-
Access the FASB Accounting Standards Codification at the FASB website (asc.fasb.org). Determine the specific citation for accounting for each of the following items: 1. Disclosure of interest and...
-
Silven Industries, which manufactures and sells a highly successful line of summer lotions and insect repellents, has decided to diversify in order to stabilize sales throughout the year. A natural...
-
A _____________ plot can be used to determine whether a multiple regression equation is appropriate. In Exercises 7 and 8, fill in each blank with the appropriate word or phrase.
-
Income statements for Thompson Company for 2011 and 2012 follow. Required a. Perform a horizontal analysis, showing the percentage change in each income statement component between 2011 and 2012. b....
-
Define the ethical minimum and ethical maximum for Apple in the given situation? (10 Points) 2. On behalf of Apple, define the stakeholders under different stakeholder's categories? (10 Points) 3. Do...
-
For this assignment, you will use Flex or Lex for the lexical part of the task. Sid=E Eid Eid E | (E) | id You will use Flex to capture the tokens of the language. Hint: There are lots of online...
-
Premier Corporation has an ROE of 14.1 percent and a payout ratio of 25 percent. What is its sustainable growth rate? (Do not round intermediate calculations and enter your answer as a percent...
-
What are some of the issues you see in current events, especially in criminal justice and security, that relate to organizational behavior?
-
Describe the four different legal entities recognized by the US tax system and the fundamental differences in the characteristics across business entities. Include the pros and cons of transitioning...
-
1. 2. State the extended accounting equation, explaining each component and providing two (2) examples of each one. There are many Accounting conventions that must be adhered to by Accountants and...
-
Drinking cold water forces your body to expend calories to heatthe water to body temperature. Drinking ice water requires evenmore energy, because energy must be used to melt the ice to water,then...
-
why is the answer c instead of B 9. The name of PbO2 is A) lead dioxide. B) lead(II) oxide. C) lead(IV) oxide. D) plumbum oxide. E) lead oxygen. Answer: C
-
Define relevant costs and discuss: (1) whether all future costs are relevant for decision making and (2) whether variable costs are always relevant and fixed costs are always irrelevant
-
Write a program that will read a text file that contains an unknown number of movie review scores. Read the scores as Double values and put them in an instance of ArrayList. Compute the average score.
-
Repeat Programming Project 10 from Chapter 5, but include constructors. Programming Project 10 Consider a class Movie that contains information about a movie. The class has the following attributes:...
-
Define a class called TicTacToe. An object of type TicTacToe is a single game of tic-tactoe. Store the game board as a single two-dimensional array of base type char that has three rows and three...
-
Tom Jones, CPA, is auditing the financial statements of a manufacturing company with a significant amount of trade accounts receivable. Jones is satisfied that the accounts are properly summarized...
-
Your regular annual audit of Palisades, Inc., included the confirmation of accounts receivable. You decided to use the positive form of confirmation request. Satisfactory replies were received from...
-
Walter Conn, CPA, is engaged to audit the financial statements of Matthews Wholesaling for the year ended December 31,200X. Conn obtained and documented an understanding of internal control relating...
Study smarter with the SolutionInn App