COMP 325 Midterm: 16
85 views2 pages
30 Jun 2018
School
Department
Course
Professor
16. Why does a shell process terminate when you press <Ctrl-D> at the beginning of a new
line?
Every UNIX file has an end-of-file (eof) marker. The commands that read their input
from files read the eof marker when they reach the end of a file. For files that can be
stored, the value of the eof marker is not a character; it is usually a small negative integer
such as -1. The <Ctrl-D> on a new line is the UNIX eof marker when the input file is
a keyboard. That is why commands such as cat while reading input from the keyboard
(see Chapter 9) terminate when you press <Ctrl-D> on a new line.
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.
https://unix.stackexchange.com/questions/174133/number-of-files-in-a-directory-
starting-with-specific-text
find more resources at oneclass.com
find more resources at oneclass.com
Unlock document
This preview shows half of the first page of the document.
Unlock all 2 pages and 3 million more documents.
Already have an account? Log in
Get access
Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers