0% found this document useful (0 votes)
39 views

Os Lab Question

This document contains a list of 30 assignments for an Operating Systems lab at the Calcutta Institute of Engineering and Management. The assignments include writing shell scripts to perform basic math operations, check for palindromes, implement patterns, copy and search files, count lines and words, implement scheduling algorithms like FCFS, SJF, and Round Robin, and demonstrate threading using pthreads. They cover a range of fundamental operating systems and Linux commands concepts.

Uploaded by

beasd2003
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
39 views

Os Lab Question

This document contains a list of 30 assignments for an Operating Systems lab at the Calcutta Institute of Engineering and Management. The assignments include writing shell scripts to perform basic math operations, check for palindromes, implement patterns, copy and search files, count lines and words, implement scheduling algorithms like FCFS, SJF, and Round Robin, and demonstrate threading using pthreads. They cover a range of fundamental operating systems and Linux commands concepts.

Uploaded by

beasd2003
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

CALCUTTA INSTITUTE OF ENGINEERING AND MANAGEMENT

List of Assignments
Operating System Lab (PCC-CS592)
Dept : CSE

Sl no. Assignments

1 Implement the basic Linux commands.

2 Implement the following tree using Linux commands:


CIEM

CSE
1st_Year
2nd_Year DAA_Lab
3rd_Year OS_Lab
4th_Year
ECE

IT
1st_Year
2nd_Year DAA_Lab
3rd_Year OS_Lab
4th_Year

EE

3 Write a shell script to add, subtract, multiply and divide two numbers.

4 Write a shell script to show addition of two numbers using Command Line Arguments.

5 Write a shell script to show Swapping of two numbers using and without using 3 rd variable.

6 Write a shell script to check whether a number is even or odd.

7 Write a shell script to find the biggest among three numbers.

8 Write a shell script that calculates the average marks of a student considering that number of subjects
are five and also calculate the corresponding grade on average.

9 Write a menu driven program which performs the following operations:


i) Addition
ii) Subtraction
iii) Multiplication
iv) Division

10 Write a shell script to print a number in reverse order.

11 Write a shell script to find Factorial of a number.

12 Write a shell script to check a number is Palindrome or not.

13 Write a shell script to check a number is Armstrong or not.

14 Write a shell script to reverse a string.


15 Write a shell script to combine two strings in a variable.

16 Write a shell script to draw the following patterns:


a) b) c) d) e) f) g)
| **** 1 1 1 * * * * * * * *
| | *** 12 22 23 * * * * * * * *
| | | ** 123 3 3 3 456 * * * * * * * *
| | | | * 1234 4 444 7 8 9 10 * * * * * * * *

17 Write a menu driven shell script-


a) Create two blank files at a time,
b) Add some content in an existing file,
c) Copy the content of one file into another file,
d) Search and print the lines which contain a specific word,
e) Count the total number of files whose name starts with a vowel.

18 Write a shell script which calculates total number of files and sub-directories present in a specific
directory.

19 Write a shell script which counts total number lines in a file without using wc -l command.

20 Write a shell script which works similar to wc command. Script can receive the options – -l, -w and -
c to indicate whether number of lines, number of words, number of characters from the input string
is to be counted. The user may use any all of options. Your script should be intelligent enough to
identify invalid options and reject them.

21 A shell script receives even number of file names, suppose 4 file names are supplied, then 1st file
should get copied into the 2nd file and 3rd file should get copied into the 4th file, so on. If odd number
of files are supplied, no copy should take place and an error message should be displayed.

22 Write a shell script to implement the Fibonacci series using function.

23 Write a shell script to check whether a number is Palindrome or not by using function.

24 Write a shell script which implement a process and perform a task of printing a word “Happy
Birthday”.

25 Write a script to implement First Come First Served (FCFS) CPU Scheduling Algorithm.

26 Write a script to implement Shortest Job First (SJF) CPU Scheduling Algorithm.

27 Write a script to implement Round Robin (RR) CPU Scheduling Algorithm.

28 Write a Linux/Unix C program for the implementation of Producer Consumer algorithm using
Semaphore.

29 Write a script to implement Banker’s Algorithm.

30 Write a script to demonstrate the use of pthread basic functions.

You might also like