You are on page 1of 8

COMP 83

LINUX 1
Lab 3

Student Name: Dilpreet Singh

Student ID: 4326286432662

Date: 21/06/2021
The name of the machine should be YourName-XXX, where XXX is the last 3 digits of your student
ID. Whenever possible make sure your screenshots are showing the name of the Linux machine on
the command-line.

1. Using the vi editor, create the file budget.txt with the following content, then using an appropriate
command display the content of the file on the display.

Using the snipping tool paste the command you used and the output below.

2. Using the vi editor, create the file budgetB.txt with the following content, then using an appropriate
command display the content of the file on the display.

Using the snipping tool paste the command you used and the output below.
3. Using the two files you created, apply the appropriate command to obtain the following output.

Using the snipping tool paste the command you used and the output below.
4. Using the two files you created, apply the appropriate command to obtain the following output

Using the snipping tool paste the command you used and the output below.

5. Using the vi editor, create the file Sales.txt with the following content, then using an appropriate
command display the content of the file on the display.

Using the snipping tool paste the command you used and the output below.
6. Combine budget.txt and Sales.txt to obtain the following output using the appropriate command

Using the snipping tool paste the command you used and the output below.

7. Combine budget.txt and Sales.txt just as you did above but this time write the output to a file data3.txt,
Below is an example of what data3.txt should look like when displayed with the cat command.

Using the snipping tool paste the command you used and the output below.
8. Sort data3.txt and write the output to a file data4.txt. then display the content of data4.txt to obtain the
following output. [3]

Using the snipping tool paste the command you used and the output below.
9. Sort the budgetB.txt file you created earlier to obtain the following output.

Using the snipping tool paste the command you used and the output below.

10. Use the appropriate command to change the value 19500 to 28500 in the Sales.txt file, such that
Sales.txt will be updated as follows.

Using the snipping tool paste the command you used and the output below.

Marking Rubrics
No submission 0/10
Complete or incomplete submission after cut 3/10
off time
Complete less than 80% of task before cut off 5/10
time
Complete less than 80% of task within time 6/10
limit
Complete at least 80% of task before cut off 7/10
time
Complete at least 80% of tasks within time 8/10
limit
Complete all tasks before the cut off limit 9/10
Complete all tasks within time limit 10/10

Mark:__________

~End of Lab~

You might also like