Question: Write in C language. Thanks! Problem: Given an integer to serve as a seed for the random number generator and the desired data set size,

Write in C language. Thanks!
Problem: Given an integer to serve as a seed for the random number generator and the desired data set size, generate the
specified number of random integers in the range 0to 7(inclusive).As described in the previous lab, these integers will
represent the permissions for a set of files. Each file has three permissions: Read (can the user see the contents of the
file?),Write (can the user change the contents of the file?),and eXecute (can the user execute the contents of the file as a
new program?).The following three rules are used to translate the permission integer into read, write, and execute
permissions:
A.If the permission integer is greater than or equal to four, then the user has Read permission for the file.
B.If the permission integer is two, three, six, or seven, then the user has Write permission for the file.
C.If the permission integer is odd, then the user has eXecute permission for the file.
The final pair of input will include two characters, the first of which will indicate to add '+'or remove '-',and the second
the desired permission on which to act. For examples, -r would indicate ALL files should have the read permission
removed and +w will add the write permission to ALL files.
Hint: this assignment requires character input following previous inputs. You will need to use the format string "%c "
(note the leading space)when accepting user input for the operation character, or your program will not work correctly!
Display the remaining permissions present in the data set, the number of times the permission is present among the files,
and do so in order from the permission that is least frequent to the one that is most frequent.
Write in C language. Thanks! Problem: Given an

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!