Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

using the linux command don't forget to add /home/`whom`/Desktop so I can run to my command Make sure you include comments for each line of

using the linux command don't forget to add /home/`whom`/Desktop so I can run to my command

Make sure you include comments for each line of code.

Remember that if you don't include comments, then you will receive a zero for your grade.

Advanced Array Part 1

  • make a directory called your YourFirstInitalLastnameScripts on the desktop.
  • Use the touch command to make a txt file within the directory called YourFirstInitalLastname Accounts.txt
  • Populate the usernames in the text file with a "FOR" loop by taking input from the user.
  • Use the "echo" and "read" command to made this operation. The "read" command will allow you to take input from the user.
  • Use the >> characters to append each username to your text file.

Advanced Array Part 2

  • Assign a variable called myFilename to the path to the file you made in step 1.
  • Use the "cat" command to populate your array with the $myFilename variable.
  • Use a "for" loop to run through each entry in your array and create the new users with a password of P@ssw0rd. You must have at least 5 users in your array.
  • Use the "getent" command to verify that your users were successfully created.
  • Use the "sleep" command to separate the next task from this task.

Advanced Array Part 3

  • Assign a variable called myFilename to the path to the file you made in step 1.
  • Use the "cat" command to populate your array with the $myFilename variable.
  • Use a "for" loop to run through each entry in your array and delete each user.
  • Use the "getent" command to verify that your users were successfully deleted.

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

Income Tax Fundamentals 2013

Authors: Gerald E. Whittenburg, Martha Altus Buller, Steven L Gill

31st Edition

1111972516, 978-1285586618, 1285586611, 978-1285613109, 978-1111972516

More Books

Students also viewed these Programming questions

Question

Explain how to dispute irrational beliefs. Critical T hinking

Answered: 1 week ago

Question

How to find if any no. is divisble by 4 or not ?

Answered: 1 week ago