Question 1Not yet answeredMarked out of 5.00Flag questionQue.
Question 1Not yet answeredMarked out of 5.00Flag questionQuestion textConsider the following directory listing:. dir1 subdir1 file.txtYour current directory is dir1. What is the resulting directory tree after running these commands:[you@blue final]$ mkdir dir2[you@blue final]$ mv subdir1 ../dir2Question 2Not yet answeredMarked out of 5.00Flag questionQuestion textYou want to know how many regular files that end with the .txt extension exist in your home directory (including any subdirectory). Provide a command that will return that information.For example, imagine this is a tree listing of your home directory: . dir1 foo.jpg hello.txt hello.txt.bak subdir1 bye.txt dir2 subdir2 file.txt file.pdf file.txtWhen you run your command, the output should be:4Question 3Not yet answeredMarked out of 5.00Flag questionQuestion textLook at the following output:total 16drwxrwxr-x 4 you you 4096 May 10 20:34 .drwxrwxr-x 4 you you 4096 May 10 19:35 ..-rw-rw-r 1 you you 0 May 10 20:34 .bardrwxrwxr-x 3 you you 4096 May 10 19:56 dir1drwxrwxr-x 3 you you 4096 May 10 19:52 dir2-rw-rw-r 1 you you 0 May 10 19:51 file.pdf-rw-rw-r 1 you you 0 May 10 19:51 file.txtwhich of the following commands produced that output:Select one:A. ls -lB. ls -laC. ls -lhaD. ls -lthE. ls -ltQuestion 4Not yet answeredMarked out of 5.00Flag questionQuestion textProvide a command that will output all the possible combinations with repetition of the characters a, b and c.The output of your command should be:aaa aab aac aba abb abc aca acb acc baa bab bac bba bbb bbc bca bcb bcc caa cab cac cba cbb cbc cca ccb cccQuestion 5Not yet answeredMarked out of 5.00Flag questionQuestion textReplace XXX with the appropriate argument in the following mkdir command so it will create the directories listed below:[you@blue final]$ mkdir XXX[you@blue final]$ lsprod-docs-2001 prod-log-2006 qa-docs-2001 qa-log-2006 test-docs-2001 test-log-2006prod-docs-2002 prod-log-2007 qa-docs-2002 qa-log-2007 test-docs-2002 test-log-2007prod-docs-2003 prod-log-2008 qa-docs-2003 qa-log-2008 test-docs-2003 test-log-2008prod-docs-2004 prod-log-2009 qa-docs-2004 qa-log-2009 test-docs-2004 test-log-2009prod-docs-2005 prod-log-2010 qa-docs-2005 qa-log-2010 test-docs-2005 test-log-2010prod-docs-2006 prod-src-2001 qa-docs-2006 qa-src-2001 test-docs-2006 test-src-2001prod-docs-2007 prod-src-2002 qa-docs-2007 qa-src-2002 test-docs-2007 test-src-2002prod-docs-2008 prod-src-2003 qa-docs-2008 qa-src-2003 test-docs-2008 test-src-2003prod-docs-2009 prod-src-2004 qa-docs-2009 qa-src-2004 test-docs-2009 test-src-2004prod-docs-2010 prod-src-2005 qa-docs-2010 qa-src-2005 test-docs-2010 test-src-2005prod-log-2001 prod-src-2006 qa-log-2001 qa-src-2006 test-log-2001 test-src-2006prod-log-2002 prod-src-2007 qa-log-2002 qa-src-2007 test-log-2002 test-src-2007prod-log-2003 prod-src-2008 qa-log-2003 qa-src-2008 test-log-2003 test-src-2008prod-log-2004 prod-src-2009 qa-log-2004 qa-src-2009 test-log-2004 test-src-2009prod-log-2005 prod-src-2010 qa-log-2005 qa-src-2010 test-log-2005 test-src-2010Question 6Not yet answeredMarked out of 5.00Flag questionQuestion textRecall the /etc/passd file, which contains a list of users and their properties. Provide a command that will print the user that has the highest user ID (when comparing using numerical value). For example, when run in blue.cs.sonoma.edu, your command should produce the following output (since user nfsnobody has the largest ID of 65534)The user with the highest ID is nfsnobodyQuestion 7Not yet answeredMarked out of 5.00Flag questionQuestion textProvide a command that will assign the number of users in /etc/passwd to an environment variable called TOTAL_USERS.Recall that environment variables can be verified by using the env command. For example, after running your command that sets the environment variable TOTAL_USERS, you can verify by executing the following command (there were 1077 users in blue when this question was written).[you@blue final]$ env | grep TOTAL_USERSTOTAL_USERS=1077Question 8Not yet answeredMarked out of 5.00Flag questionQuestion textCreate a shell script that will take 1 argument and will end with a success exit code if the argument is a whole word in the /usr/share/dict/words file, and it will return an error signal of 1 if the argument is not a word on that file.Your script should not produce any outputFor example, if your script is called isvalid.sh, then you will see the following output (bad is a word in the dictionary, badd is not a word in the dictionary):[you@blue final]$ ./isvalid.sh bad[you@blue final]$ echo $?0[you@blue final]$ ./isvalid.sh badd[you@blue final]$ echo $?1Question 9Not yet answeredMarked out of 5.00Flag questionQuestion textIn Lab. No 1 we made calls to the Internet Chuck Norris Data Base API using curl. Write a script that takes a joke number as an argument and prints the joke to the screen.For example, if your script is called chuck.sh, then you should have the following output:[you@blue final]$ ./chuck.sh 458Chuck Norris can write infinite recursion functions and have them return.[you@blue final]$ ./chuck.sh 459Chuck Norris can solve the Towers of Hanoi in one move.[you@blue final]$ ./chuck.sh 460The only pattern Chuck Norris knows is God Object.Question 10Not yet answeredMarked out of 5.00Flag questionQuestion textThe driver s licenses in the island nation of Lilliput follow the format XYX-1111-A (three alphabetic characters followed by a hyphen followed by a four digit number, followed by another hyphen and finally another character that indicates the license type which can only be B for Bicycle, C for Carriage, D for Donkey Cart and A for All.)Write a script that takes an argument and returns a success exit code if the argument is a valid Lilliputian drivers license or 1 if it is not a valid one. For example, if your script is called dlcheck.sh:[you@blue final]$ ./dlcheck.sh ACV-13-A[you@blue final]$ echo $?1[you@blue final]$ ./dlcheck.sh ACV-13119-A[you@blue final]$ echo $?1[you@blue final]$ ./dlcheck.sh ACV-1319-A[you@blue final]$ echo $?0[you@blue final]$ ./dlcheck.sh ACV-1319-Y[you@blue final]$ echo $?1
Question 1Not yet answeredMarked out of 5.00Flag questionQue
Consider the following information, and answer the question below. China and England are international trade…
The CPA is involved in many aspects of accounting and business. Let's discuss some other…
For your initial post, share your earliest memory of a laser. Compare and contrast your…
2. The Ajax Co. just decided to save $1,500 a month for the next five…
How to make an insertion sort to sort an array of c strings using the…
Assume the following Keynesian income-expenditure two-sector model: AD = Cp + Ip Cp = Co…