PROBLEM SAMPLE 2
Q5 (18 points)
N customers enter the bakery to buy cookies. Each customer gets its turn[i], by computing a next
number, and waits to be served. The clerk uses a counter to keep track of the served customers.
The clerk serves the customer
Fork (): System call fork () is used to create new processes. It takes no arguments and returns a
process ID. The newly created process is called child, the calling process is called parent. After a
new child is newly created
CS340 Homework 1
Part A: What is MS Windows and UNIX operating system?
MS Windows is the most popular operating system used in the world. MS-DOS is the
earliest consumer operating system that first caught peoples attention. The major
Assume that we have a demand-paged memory. The page table is held in registers. It
takes 8 milliseconds to service a page fault if an empty frame is available or if the
replaced page is not modified, and 20 milliseconds if the replaced page modified.
CS 340 HW 4
-[[email protected] ~]$ ls -l >dirlist&
[[email protected] ~]$ fg 1
fg: No such job.
ls -color=auto -l > dirlist
It shows job number  of the process (pid33168) that is not running in the foreground
[[email protected] ~/cs
Root Directory (/)
The root directory is the top of the file system. It is the master cabinet that contains all folders and files.
1. Get a listing of your root directory. ( use, cd and ls Cl)
[[email protected] ~]$ cd /
[[email protected] /]$ ls -l