Last login: Thu Nov 29 15:06:13 on ttys015
Math-Tuttle-OSX:~ smtuttle$ cd humboldt/f12cs279/279lectures/279lect14-2

Math-Tuttle-OSX:279lect14-2 smtuttle$ uptime
15:22  up 14 days, 10:31, 18 users, load averages: 0.89 1.00 1.22

Math-Tuttle-OSX:279lect14-2 smtuttle$ w
15:23  up 14 days, 10:32, 18 users, load averages: 0.84 0.97 1.20
USER     TTY      FROM              LOGIN@  IDLE WHAT
smtuttle console  -                15Nov12 14days -
smtuttle s000     -                20Nov12 8days emacs 100hw
smtuttle s001     -                15Nov12    51 emacs 279wo
smtuttle s002     -                Mon23      31 -bash
smtuttle s003     -                Wed11   17:34 -bash
smtuttle s004     -                16Nov12  3:13 emacs 100wo
smtuttle s005     -                16Nov12  1:21 emacs 235wo
smtuttle s006     -                Tue00   2days grotty
smtuttle s007     -                Tue08      58 ssh st10@nr
smtuttle s008     -                Tue12   1day  emacs 100le
smtuttle s009     -                Wed14   22:10 emacs 279la
smtuttle s010     -                 9:50    4:37 ssh st10@nr
smtuttle s011     -                12:22    2:50 -bash
smtuttle s012     -                Wed16   21:16 -bash
smtuttle s013     -                12:35    1:21 emacs 100le
smtuttle s014     -                15:05       1 emacs 279le
smtuttle s015     -                15:06       6 ssh st10@nr
smtuttle s016     -                15:22       - w

Math-Tuttle-OSX:279lect14-2 smtuttle$ top
<you don't see anything in this saved screen shot, but it
resulted in a "live" full-screen output of the processes in order
of CPU usage, updated frequently;.

Math-Tuttle-OSX:279lect14-2 smtuttle$ IFS="+"

Math-Tuttle-OSX:279lect14-2 smtuttle$ read var1
moo

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo $var1
moo

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo $IFS

Math-Tuttle-OSX:279lect14-2 smtuttle$ read a b c d
3+7+9+12

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "<$a> <$b> <$c> <$d>"
<3> <7> <9> <12>

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "$IFS"
+

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo $a
3

Math-Tuttle-OSX:279lect14-2 smtuttle$ read a b c d
3 4 5 6

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "<$a> <$b> <$c> <$d>"
<3 4 5 6> <> <> <>

Math-Tuttle-OSX:279lect14-2 smtuttle$ read a b c d3+4+5+6+7+8+9+10+11

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "<$a> <$b> <$c> <$d>"
<3> <4> <5> <6+7+8+9+10+11>

Math-Tuttle-OSX:279lect14-2 smtuttle$ emacs ifs-play.sh

[1]+  Stopped                 emacs ifs-play.sh

Math-Tuttle-OSX:279lect14-2 smtuttle$ ifs-play.sh nba
please type in something, followed by enter:
moonriverflowingtothesea
<$first> is <moo>
<$second> is <riverflowi>
<$third> is <gtothese>
<$fourth> is <>

Math-Tuttle-OSX:279lect14-2 smtuttle$ ifs-play.sh '[0-9]'
please type in something, followed by enter:
moo-moo3skidoo23oink
<$first> is <moo>
<$second> is <moo3skidoo23oink>
<$third> is <>
<$fourth> is <>

Math-Tuttle-OSX:279lect14-2 smtuttle$ ifs-play.sh "[0-9]"
please type in something, followed by enter:
moo-mooskidoo23oink
<$first> is <moo>
<$second> is <mooskidoo23oink>
<$third> is <>
<$fourth> is <>

Math-Tuttle-OSX:279lect14-2 smtuttle$ fg
emacs ifs-play.sh

[1]+  Stopped                 emacs ifs-play.sh

Math-Tuttle-OSX:279lect14-2 smtuttle$ source ifs-play.sh "- "please type in something, followed by enter:
moo-oink la-la la
<$first> is <moo>
<$second> is <oink>
<$third> is <la>
<$fourth> is <la la>

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "$IFS"
- 

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "<$IFS>"
<- >

Math-Tuttle-OSX:279lect14-2 smtuttle$ ifs-play.sh moo
please type in something, followed by enter:
moomoomoomoo
<$first> is <>
<$second> is <>
<$third> is <>
<$fourth> is <moomoomoo>

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "<$IFS>"
<- >

Math-Tuttle-OSX:279lect14-2 smtuttle$ fg
emacs ifs-play.sh

[1]+  Stopped                 emacs ifs-play.sh

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "<$IFS>"
<- >

Math-Tuttle-OSX:279lect14-2 smtuttle$ source ifs-play.sh '*!'
please type in something, followed by enter:
how*now!brown*!cow
<$first> is <how>
<$second> is <now>
<$third> is <brown>
<$fourth> is <!cow>

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "<$IFS>"
<*!>

Math-Tuttle-OSX:279lect14-2 smtuttle$ fg
emacs ifs-play.sh

[1]+  Stopped                 emacs ifs-play.sh

Math-Tuttle-OSX:279lect14-2 smtuttle$ fg
emacs ifs-play.sh

Math-Tuttle-OSX:279lect14-2 smtuttle$ IFS=";-"

Math-Tuttle-OSX:279lect14-2 smtuttle$ read first second third fourth fifth sixth
what;where-how now;brown-cow

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo [$first] [$second] [$third] [$fourth] [$fifth] [$sixth]
[what] [where] [how now] [brown] [cow] []

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "<$IFS>"
<;->

Math-Tuttle-OSX:279lect14-2 smtuttle$ IFS="$IFS."

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "<$IFS>"
<;-.>

Math-Tuttle-OSX:279lect14-2 smtuttle$ read a b c
moo.oink-la;

Math-Tuttle-OSX:279lect14-2 smtuttle$ echo "$a $b $c"
moo oink la

Math-Tuttle-OSX:279lect14-2 smtuttle$