Answered step by step
Verified Expert Solution
Question
1 Approved Answer
i forgot to speicify, could you please do the question c langauge. Suppose we have n programs p 1 , . . . , pn
i forgot to speicify, could you please do the question c langauge. Suppose we have n programs ppn to be executed. The programs are described in an
input text file that looks like the left column below with descriptions on the right:
n n is the number of programs.
path The subsequent n lines contain the fully qualified
paths of the programs to be executed ordered
pathn
from to n
Figure : Sample input file
a Suppose the programs are independent from each other, so that they can be executed in
parallel. Write a parallel program executor, receiving the absolute path of the above
mentioned input file as a commandline argument. This program runs all the programs listed
in the file in parallel.
b Now suppose each program pi depends on all the programs ppi This means the
programs should be executed sequentially, first completing p then p and so on Modify the
parallel program executor you designed in part a to obtain a sequential program executor
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