Code Monkey home page Code Monkey logo

cmsc125_mp1's Introduction

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

cmsc125_mp1's People

Contributors

rosalierazonable avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.