Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

QUESTION 1 From my home directory, copy the file called cards to your home directory. Copy the following script to a file in your home

QUESTION 1 From my home directory, copy the file called cards to your home directory. Copy the following script to a file in your home directory. This will be your first shell script. You can name the file any name that you would like. Once the file exists, execute the script. #!/usr/bin/ksh grep -i 'Mantle' cards if [ $? ] then echo "The name Mantle was found" fi The above script will locate the string "Mantle" within the file called cards and output the lines and a success statement. True False 10 points QUESTION 2 Copy the following script to a file in your home directory. You can name the file any name that you would like. #!/usr/bin/ksh if [ -f /etc/passwd ] then echo "The file exists" else echo "The file does not exist" fi Execute the file (script) The script will locate the /etc/passwd file and tell you that it exists True False 10 points QUESTION 3 Copy the file called list from my home directory. Copy the following script to a file in your home directory. You can name the file any name you would like. #!/usr/bin/ksh for index in `cat list` do echo $index done Execute the file (script). The script will output each line contained in the file called list. True False 10 points Click Save and Submit to save and submit. Click Save All Answers to save all answers.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Fundamentals Of Database Management Systems

Authors: Mark L. Gillenson

2nd Edition

0470624701, 978-0470624708

More Books

Students also viewed these Databases questions

Question

What is the relation of physical mathematics with examples?

Answered: 1 week ago

Question

What are oxidation and reduction reactions? Explain with examples

Answered: 1 week ago