part 1write a cc program to read a data file and


PART 1:

Write a C/C++ program to read a data file and extract parameters. The program must obtain the filename via a command-line argument. The file will be called "cs451.conf". Your code must extract the value after the ":".

Here is a sample data file.

Maximum number of processes: 1000
Time quantum: 100
Heavy context switch time: 100
Light context switch time: 10

Your program should extract the 1000, 100, 100, and 10

PART 2:

Write a C/C++ queue "class" and add it to your program. At this point the only item that should be stored in the queue is the context switch time (we will assume that heavyweight and lightweight process may have difference context switch times).

P.S. You may want to explore the standard templates for a queue class

Eventually, your program will create a Ready Queue that can hold the "Maximum number of processes".

Solution Preview :

Prepared by a verified Expert
C/C++ Programming: part 1write a cc program to read a data file and
Reference No:- TGS0442535

Now Priced at $20 (50% Discount)

Recommended (93%)

Rated (4.5/5)