CS 307 Programming Examples, Spring 2000
- From class on 3/27/00.
forktest.c (simple creation of a child),
exectest.c (elementary illustration of "exec"),
and getanumber.c (needed by
exectest.c).
- From class on 3/29/00.
unsharedmem.c (a demonstration that global
variables are not shared after a fork) and
sharedmem.c (using shared memory).
- From class on 4/3/00.
race.c (a demonstration of a failed lock-variable
strategy for avoiding race conditions), and
norace.c (an example of how to use a binary
semaphore to avoid the problem in race.c).
Jeff Ondich,
Department of Mathematics and Computer Science,
Carleton College, Northfield, MN
55057
(507) 646-4364,
jondich@carleton.edu