From 382b28eb015fedfeb316510367119ea1c126e70a Mon Sep 17 00:00:00 2001 From: mokha Date: Sat, 18 May 2019 14:48:45 -0600 Subject: do course stuff --- README.md | 37 +++++++++++++++++++++++++++++++++++++ README.pdf | Bin 0 -> 86413 bytes exercises/chapter-7.15 | 9 +++++++++ 3 files changed, 46 insertions(+) create mode 100644 README.pdf create mode 100644 exercises/chapter-7.15 diff --git a/README.md b/README.md index 318bf59..2791324 100644 --- a/README.md +++ b/README.md @@ -73,7 +73,44 @@ bash-3.2$ ls /Users/mokha/memos/memo.james /Users/mokha/memos/memo.james ``` +15. Give the command for deleting the memos directory. How do you know that the directory has been deleted? + +```bash +bash-3.2$ cd +bash-3.2$ rm -fr memos/ +bash-3.2$ ls -alh memos +``` + +16. Why does a shell process terminate when you press at the beginning of a new line? + +```text +The ^D represents the eof or end of file. +``` + +```bash +モ stty -a +speed 9600 baud; 14 rows; 238 columns; +lflags: icanon isig iexten echo echoe -echok echoke -echonl echoctl + -echoprt -altwerase -noflsh -tostop -flusho pendin -nokerninfo + -extproc +iflags: -istrip icrnl -inlcr -igncr -ixon ixoff ixany imaxbel iutf8 + -ignbrk brkint -inpck -ignpar -parmrk +oflags: opost onlcr -oxtabs -onocr -onlret +cflags: cread cs8 -parenb -parodd hupcl -clocal -cstopb -crtscts -dsrflow + -dtrflow -mdmbuf +cchars: discard = ^O; dsusp = ^Y; eof = ^D; eol = ; + eol2 = ; erase = ^?; intr = ^C; kill = ^U; lnext = ^V; + min = 1; quit = ^\; reprint = ^R; start = ^Q; status = ^T; + stop = ^S; susp = ^Z; time = 0; werase = ^W; +``` +17. Give a command line to display the types of all the files in your ∼/unix directory that start with the word chapter, are followed by a digit 1, 2, 6, 8, or 9, and end with .eps or .prn. + + 2. Solve problems 7–17 at the end of Chapter 8. + + + + 3. Do problem 9 (What do the following commands do?) in Chapter 9. 4. Enter a C program that reads a temperature in Celsius entered from a keyboard and displays the corresponding temperature in Fahrenheit and complete the steps below. (Hint: Look for such a program in the textbook or online.) diff --git a/README.pdf b/README.pdf new file mode 100644 index 0000000..0354b1a Binary files /dev/null and b/README.pdf differ diff --git a/exercises/chapter-7.15 b/exercises/chapter-7.15 new file mode 100644 index 0000000..d649ad2 --- /dev/null +++ b/exercises/chapter-7.15 @@ -0,0 +1,9 @@ +Script started on Sat May 18 14:42:25 2019 +bash-3.2$ cd +bash-3.2$ rm -fr memos/ +bash-3.2$ ls -alh memos +ls: memos: No such file or directory +bash-3.2$ exit +exit + +Script done on Sat May 18 14:42:40 2019 -- cgit v1.2.3