Comp 2673
Spring 2002
Homework 1 solutions
-
-
-
The -b flag for diff ignores repeating blanks and end-of-line blanks.
In other words, if one file has extra spaces in the middle of a line
or at the end, then diff sees them as the same.
To compare the two programs, ignoring all differences in case and
white space, say
% diff -wi Janeprogram.cpp Martinprogram.cpp
-
% grep apple ~ftl/foodir/*
The word "apple" shows up in foo18, foo23 and foo9
- The permissions are rwx---r-x, which means the the owner can
read, write, and execute, group members have no permissions, and others
can read and execute.
- type env, and look at the value of the PATH environment variable.
It gives the list of directories searched when you enter a command.
These can be changed, but for new users are set to:
/usr/local/bin
/usr/ccs/bin
/usr/bin
/usr/dt/bin
/usr/X/bin
/usr/X/demo
/usr/ucb
/usr/local/scripts
/usr/local/maple/bin
/usr/local/perl/bin
/usr/local/tex/bin
/u/home/yourusername/bin
. (your current directory)
-
% du /usr/bin
Multiply by 512 to get total number of bytes. On evans, for example,
we have 18542x512 bytes.