* rawgetc ** uses the terminal interface to change the config for char-by-char reads ** reads one char and then sets it back ** we'll cover the lower level details later in the term * what are the bugs? or how to identify them? ** test strategy - for validation, compare with more - two files as input 'q', ' ', '\n' - read from stdin (this is piping output from last into more03) 'q', ' ', '\n' - test for corner cases and various different user behaviors in order to identify possible bugs; don't assume the assignment spec (or our test suites) identify absolutely everything ** generating typescripts - execute all of the important test cases - some behaviors will produce strange results in the typescript - if we provide a test script, always include a run in the typescript * debugging strategy - leverage the GDB manual to learn how to do sessions https://sourceware.org/gdb/current/onlinedocs/gdb.html/index.html - VScode can be used here, including for debugging, but the teaching staff doesn't use it so we're great sources of expertise - if the debugger doesn't help (or work) for the particular assignment add debug output to the program, always to stderr fprintf(stderr, ...); ./myprog 2> output.stderr // in a separate terminal, use tail -f output.stderr to see the output // in real time * for systems programming - think carefully about the tradeoff between memory use and performance - account for files of lots of different sizes - try to limit resource use to only what is necessary ** we require a program Plan with every assignment do that early and get one of the staff review * reviewing material about grading standards ** make sure you read over all of the material on the projects page