Posts

Showing posts with the label refactor

C: Improved ascending and descending for loop.

Image
Improved ascending and descending for loop with alternate example and compilation comparison. Repl: https://replit.com/@pereiradaniel/Exercise-4-3-refactor-4 Git repo: https://github.com/pereiradaniel/c_programs/blob/master/asc_desc_for/asc_desc_for2.c  

C: Character code printout with main loop repeat.

Image
Refactored version of previous program: https://youtu.be/fYuV8NQ1ieo Program loops until user quits. Git repo: https://github.com/pereiradaniel/beginning_c/blob/master/ch4/exercises/4_3/refactor2.c

C: Refactored character code table printer.

Image
Refactored version of previous program: https://youtu.be/W8me8An2fA4 Extend the previous program to output the appropriate name, such as “newline”, “space”, “tab”, and so on, for each whitespace character. Git repo: https://github.com/pereiradaniel/beginning_c/blob/master/ch4/exercises/4_3/exercise4_3.c