CS208 Introduction to Computer Systems Friday, 9 January 2026 + Quiz on Monday, Jan 12 - bitwise operators (|, &, ~, ^) - numbers will be represented as hexadecimal - Example question: Given 8-bit numbers a = 0xE5 and b = 0x3C, express ~a, a&b, and a|b as 2-digit hexadecimal numbers. + Questions + Today - Samples - Monday's assignment + Samples in general - What should you do when studying one? - run it - experiment with it - read & understand - meta-analysi: why is Jeff giving us this sample? - Pedagogical comments vs. production comments + Samples - args.c - byte-counter.c - strings.c - [if there's time] output.c ===== #include int main() { int a = 0xE5; int b = 0x3C; printf("0x%x\n", a | b); printf("0x%x\n", a & b); printf("0x%x\n", a ^ b); printf("0x%x\n", ~a); return 0; }