Question: C + + Programming Process Schedule Please Assist Instructions: I need the code changed to be an input txt file ( use notepad ) rather
C Programming
Process Schedule Please Assist
Instructions: I need the code changed to be an input txt file use notepad rather than cin input format like below. Please input BSIZE KB START msCORE ms of CPU Time, READ B SSDCORE msDISPLAY msCORE msINPUT ms CORE msWRITE B SSDCORE msNEW msCORE ms
The inputs above are in correct order. Their values are mentioned above as well. Please have the txt file able to be uploaded so the program's steps mentioned above will be used sequentially.
Each step should have READY, RUNNING, BLCOKED, or TERMINATED if the step is READY to take the value from the text file, is RUNNING the value from the text file, BLOCKED if the value is not being taken from the text file, or is TERMINATED because the value is unable to be taken from the text file.
Program so far:
#include
#include
using namespace std;
struct Process
int bsize;
int starttime;
int coretime;
int coretime;
int coretime;
int coretime;
int coretime;
int readsize; Is read measured in size or time? Also is the unit B bytes or does it stand for something else?
int inputtime; ask a tutor if they want a sleep function rather than an input of ms
int displaytime;
int writesize;
;
int main
Input values
Process process;
cout "Enter b size KB: ;
cin process.bsize; KB
cout "Enter start time ms: ;
cin process.starttime; ms
cout "Enter core time ms: ;
cin process.coretime; ms
cout "Enter read size B: ;
cin process.readsize; B
cout "Enter core time ms: ;
cin process.coretime; ms
cout "Enter display time ms: ;
cin process.displaytime; ms
cout "Enter core time ms: ;
cin process.coretime; ms
cout "Enter input time ms: ;
cin process.inputtime; ms
cout "Enter core time ms: ;
cin process.coretime; ms
cout "Enter write size in bytes: ;
cin process.writesize; bytes
cout "Enter core time ms: ;
cin process.coretime; ms
Displaying entered process information
cout "Process Information:
;
cout "Block Size: process.bsize KB
;
cout "Start Time: process.starttime ms
;
cout "Core Time: process.coretime ms
;
cout "Read: process.readsize B
;
cout "Core Time: process.coretime ms
;
cout "Display Time: process.displaytime ms
;
cout "Core Time: process.coretime ms
;
cout "Input Time: process.inputtime ms
;
cout "Core Time: process.coretime ms
;
cout "Write Size: process.writesize bytes
;
cout "Core Time: process.coretime ms
;
cout ;
New process information
Think of this as a part two of the process scheduling or think of it like a break in a program?
int newprocessstarttime;
int newprocesscoretime; The th core time reading
cout
Enter new process start time ms: ;
cin newprocessstarttime;
cout
Enter new process core time ms: ;
cin newprocesscoretime;
Displaying new process information
cout
New Process Information: ;
cout
Start Time: newprocessstarttime ms;
cout
Core Time: newprocesscoretime ms;
cout endl endl;
return ;
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
