an attempt to learn and remember some c and unix programming - code snippets from reading APUE (Stevens/Rago)