category~brand~qty~price
soap~hamam~234~12
soap~dettol~105~22
soap~lux~120~35
noodles~magi small~50~3
noodles~magi big~152~25
noodles~top ramen~300~5
shampoo~fiama~10~100
shampoo~lux~7~120
a. Store details of soap in a file called soap file (3)
b. Display brand and price of all products in shampoo category (4)
c. Arrange details of the file on price in reverse order (2)
5. Write a menu driven program to perform basic arithmetic operation. (20)
6. Count the number of user’s logged in. if more than 20 users are logged in, display a
Message. (15)
1. You have just logged in. Enter the command to display the current working directory. (2)
2. Create the file with some contents. List the permission of the same file. Delete the file
you created. (3)
3. Display files in a certain directory that has been modified in January (1)
4. Given the following file ,perform the following operations using it
Eid |EmpName|Addr |Dept |grade|DOB|Salary
3005|Priya |24K, Raj Road,Bombay |RND |E1 |06-11-60 |1600
3010|Preethi |10, Besant Road Chennai |Accts |E2 |21-12-70 |2000
3030|Aarthi |12, Lake View Road Bombay |MKT |S1 |1-12-60 |1500
3023|Sanjana |Jaishankar|14, Adyar, Chennai |Accts |M1|12-12-85 |2200
a. List all the details of employee not in Accts department. (3)
b. Store the employee name, salary in a file and also display it on the terminal. (3)
c. Give the command that would print out the records of all employees whose
employee code is between 3010 and 3059. (3)
5. Write a shell script to display the following menu.
String operations
i. length of string
ii. convert string to upper case
iii. convert string to lower case
String is accepted as command line argument. (20)
6. Write a shell script that determines the period for which specified user is working on the system. (15)
1. Create directories called map1, map2. Copy a file from map1 and paste it to map2 with a
new name. (3)
2. Change the permission of directory map2 for the group to read and write only. (3)
3. Display the inode number of files in the current directory (2)
4. Given the following file. Perform the following operations using it.
category~brand~qty~price
watch~titan~122~1224
watch~rolex~9~5908
watch~hmt~189~433
clock~ajanta~23~12
clock~citizen~122~22
a. Give the command to display records for the category watch along with record
number. (3)
b. Display the length of the first 3 records. (3)
c. Sort the file on price and store on it into filename sort price (3)
d. Display the category store it as file and then the price, store it as a file (3)
5. Write a menu driven shell script for
1. Printing the multiplication table (upto 12) of a number accepted from the command
line. (20)
2. Display good afternoon, good evening or good night depending upon time of day (10)