1) Read the data stored in the file "rec.txt" into an array of records containing the student ids and the student names. 2) Sort the array of records following the students' names in alphabetical order and display the sorted names on the screen. 3) Prompt the user to search for the student id by the student's name.

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question
100%

Write a complete C program that does the following:
1) Read the data stored in the file "rec.txt" into an array of records containing the student ids and the student names.
2) Sort the array of records following the students' names in alphabetical order and display the sorted names on the screen.
3) Prompt the user to search for the student id by the student's name.

 

1171203258: HOSSAIN, MARUF
1181202660: KUHAN RAJ A/L TAMIL CHEL WAM
1181203465: PONG KAI SUN
1191102443: FAIZA OSAMA ABDALLA HASHIM
1201302289:LEE JIA WEI
1201302368: SHEIKH, AHNAF AZMAIN
1201100584:HI CHIA LING
1201101509:NG CHEA YEAT
1191103201:PHUAH CHEE HAOU
1201100879: MOSTAFA ARABY MADBOULY AHMED
1191103215:TONG JUN YANG
1191103119:ANG QIZHENG
1171302286: DARWIN KUMAR A/L MUNIAN
1181101192:HAIZUN NAJWA BINTI MOHD RIFIN
1201100926:NG XUE NIE
1191302417:ALMARHOON, ALI HUSSAIN A
1201100225:HEMAN RAO A/L SUBRAMANIAM
1181100823:LIM ZHEN BANG
1161202587:SOHEIL PRAKASAN SUPPAN
1201100603:AVINASH MURALI
1181101858:CHEAH KOK YEW
1191103071:GAN WEI TONG
1201100301:KEVIN THAM ZHENG YIT
1201100648:LIM CHER AIK
1201302222:SHIVAA RUTRAN A/L NAGATHEESAN
1201100779:TAN WEI XIANG
1191100919:WONG HONG WEI
Transcribed Image Text:1171203258: HOSSAIN, MARUF 1181202660: KUHAN RAJ A/L TAMIL CHEL WAM 1181203465: PONG KAI SUN 1191102443: FAIZA OSAMA ABDALLA HASHIM 1201302289:LEE JIA WEI 1201302368: SHEIKH, AHNAF AZMAIN 1201100584:HI CHIA LING 1201101509:NG CHEA YEAT 1191103201:PHUAH CHEE HAOU 1201100879: MOSTAFA ARABY MADBOULY AHMED 1191103215:TONG JUN YANG 1191103119:ANG QIZHENG 1171302286: DARWIN KUMAR A/L MUNIAN 1181101192:HAIZUN NAJWA BINTI MOHD RIFIN 1201100926:NG XUE NIE 1191302417:ALMARHOON, ALI HUSSAIN A 1201100225:HEMAN RAO A/L SUBRAMANIAM 1181100823:LIM ZHEN BANG 1161202587:SOHEIL PRAKASAN SUPPAN 1201100603:AVINASH MURALI 1181101858:CHEAH KOK YEW 1191103071:GAN WEI TONG 1201100301:KEVIN THAM ZHENG YIT 1201100648:LIM CHER AIK 1201302222:SHIVAA RUTRAN A/L NAGATHEESAN 1201100779:TAN WEI XIANG 1191100919:WONG HONG WEI
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Follow-up Questions
Read through expert solutions to related follow-up questions below.
Follow-up Question

How about this

3) Prompt the user to search for the student id by the student's name.

Solution
Bartleby Expert
SEE SOLUTION
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY