Skip to content

Machine Problem 1 in Computer Science 125: Operating Systems

Notifications You must be signed in to change notification settings

rosalierazonable/CMSC125_MP1

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

67 Commits
 
 
 
 
 
 
 
 

Repository files navigation

CMSC125-MP1

Machine Problem 1 in Computer Science 125: Operating Systems

Multiprogramming with time-sharing systems

  • Generate a random number of resources (1-30). Label them as resource 1, resource 2, … , resource 30
  • Generate a random number of users (1-30). Label them as user 1, user 2, … , user 30.
  • Also, generate the random resource that a user will need and the length of the time that the user will use the resource (1-30 seconds)
  • The program should be able to display the status of the resources, including the user currently using the resource, the time (or time left) that the user needs to use the resource
  • The program should also be able to list the users “in waiting” of a resource, if there are any, and when these users will be able to start using the resource.
  • Finally, the program should be able to say when the resources will be free of users (meaning, no user needs to use the resource).
  • A user can only request for a specific resource once. User cannot request for a resource multiple times.
  • User request is to be sorted according to priority (by order number, in increasing order)

Data Structure/s

  • Array List
  • Queue
  • LinkedList
  • Array

Run Code Here:

https://replit.com/@rsraz/Multiprogramming

About

Machine Problem 1 in Computer Science 125: Operating Systems

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published