Giter VIP home page Giter VIP logo

os_practical_exam's Introduction

OS_Practical_Exam

PRACTICAL 1

Round Robin is a CPU scheduling algorithm where each process is assigned a fixed time slot in a cyclic way. Steps to find waiting times of all processes: 1- Create an array rem_bt[] to keep track of remaining burst time of processes. This array is initially a copy of bt[] (burst times array) 2- Create another array wt[] to store waiting times of processes. Initialize this array as 0. 3- Initialize time : t = 0 4- Keep traversing the all processes while all processes are not done. Do following for i'th process if it is not done yet. a- If rem_bt[i] > quantum (i) t = t + quantum (ii) rem_bt[i] -= quantum; c- Else // Last cycle for this process (i) t = t + rem_bt[i]; (ii) wt[i] = t - bt[i] (ii) rem_bt[i] = 0; // This process is over Once we have waiting times, we can compute turn around time tat[i] of a process as sum of waiting and burst times, i.e., wt[i] + bt[i]

PRACTICAL 2

fork() is used to create new process by duplicating the current calling process, and newly created process is known as child process and the current calling process is known as parent process. So we can say that fork() is used to create a child process of calling process.

os_practical_exam's People

Contributors

prernajha2609 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.