| .. |
|
ex1-17
|
At long, panful last, a functional version of exercise 1-17. The code has contracted considerably since the intiially architected version, with replicate() and its functionality having been eliminated as unnecessary, saving numerous cycles and ~64kB of memory, advance() has been eliminated due to creating needless complexity, hindering readability, and decreasing efficiency, and recall has been eliminated because it depended on replicate, and was also unnecessary as enumerate() now contains three lines of code that completely eliminate the need for replicate() or enumerate().
|
2025-09-19 00:00:30 +00:00 |
|
a.out
|
Add both header for the entire table, and individual headers denoting which column is which unit.
|
2025-07-29 14:17:11 -07:00 |
|
avas_1_9.c
|
Added a solution of 1-9 developed collaboratively by both of us <3
|
2025-08-14 07:15:51 +00:00 |
|
ex1-16-2.c
|
storage.txt is now created at runtime rather than being assumed to be present and empty. recall() now removes storage.txt at completion. main() now includes a check to see whether storage.txt already exists, sends an error message, and exits with code 1 if storage.txt is already present.
|
2025-09-02 21:02:47 +00:00 |
|
ex1-17-2.c
|
WIP version of ex1-17-2.c that crashes during a memory safety check in store() for some reason. If I comment out the check, it spins and segfaults. Cause unknown.
|
2025-09-16 18:54:10 +00:00 |
|
ex1_1-tempconverter.c
|
Bugfix for a spin caused by setting the value of fahr inside the for loop when it is now initialized at loop start.
|
2025-07-29 17:00:35 -07:00 |
|
ex1_1.out
|
Bugfix for a spin caused by setting the value of fahr inside the for loop when it is now initialized at loop start.
|
2025-07-29 17:00:35 -07:00 |
|
ex1_4-tempconvertercf.c
|
Implemented the objectives of Exercise 1-3 to ex1_1-tempconverter.c and then implemented the objectives of Exercises 1-3 and 1-4 to ex1_4-tempconvertercf.c.
|
2025-07-29 14:44:47 -07:00 |
|
ex1_4.out
|
Implemented the objectives of Exercise 1-3 to ex1_1-tempconverter.c and then implemented the objectives of Exercises 1-3 and 1-4 to ex1_4-tempconvertercf.c.
|
2025-07-29 14:44:47 -07:00 |
|
ex1_6-getchar.c
|
Modifications and bugfix to prevent the program from returning an error code on exit.
|
2025-08-09 23:14:04 +00:00 |
|
ex1_7-printeof.c
|
Changed 'c' to 'a' while working on other, later abaondoned changes.
|
2025-08-13 05:44:14 +00:00 |
|
ex1_7.c
|
Changed name of dumbtest.c to ex1_7.c to reflect what exercise was completed in this code.
|
2025-08-13 05:46:40 +00:00 |
|
ex1_8.c
|
Complexted exercise 1-8; count and report number of newline, tab, and blank characters in input.
|
2025-08-13 07:16:39 +00:00 |
|
ex1_9.c
|
Implementation of exercise 1-9: copying and printing input text to output, removing redundant spaces.
|
2025-08-14 06:53:38 +00:00 |
|
ex1_10-5.c
|
Added ex1_10-5.c, an implementation of an example wordcount program on pages 21/22 of KNR C, purely as an exercise to see if I could do it more efficiently than the book. This resulted in a binary that was, 138 lines long as disassembled.
|
2025-08-16 01:53:43 +00:00 |
|
ex1_10.c
|
Added comments to explain certain code behaviors in ex1_10.c so that they can be read and referred to later more easily. Future code should be properly annotated on initial commit.
|
2025-08-14 17:42:15 +00:00 |
|
ex1_10_goto.c
|
Implemented a suggestion from Affine to replace the many if statements with a single switch and only ever call getchar at one point in the code.
|
2025-08-14 22:32:02 +00:00 |
|
ex1_10_improved.c
|
Implemented suggestions from affine. Considerably simplified the program by removing initialization for 'a' prior to loop entry; 'a' is now declared as the initialization expression for the loop, performing a getchar at the same time and preventing a null byte from being printed as the first character (even though this was not visible to the user).
|
2025-08-14 20:02:00 +00:00 |
|
ex1_12.c
|
Implemented KNR C Exercise 1-12, reusing mostly modified code from my previous (optional) implementaiton of KNR C's example wordcounting program.
|
2025-08-16 02:14:40 +00:00 |
|
ex1_13.c
|
Push final version of ex1_13 to repo, as only the skeleton was included in the initial commit by mistake.
|
2025-08-21 11:52:11 -07:00 |
|
ex1_13_improved.c
|
Per suggestions and feedback from Affine, removed a loop that initialized the charCount array, since modern C allows us better ways to do this. Saved 5 instructions in the binary :3
|
2025-08-22 18:32:09 +00:00 |
|
ex1_14.c
|
KNR C exercise 1-14 implementation with some really cool optimization and tricks.
|
2025-08-23 19:49:32 +00:00 |
|
ex1_14_improved.c
|
Formatting adjustments and created initial file for exercise 1-17.
|
2025-09-05 18:49:44 +00:00 |
|
ex1_15.c
|
An implementation of exercise 1-15 that I spent far too long banging my head against over an issue that turned out to be me having flipped 5 and 9 in my math.
|
2025-08-27 00:13:13 +00:00 |
|
ex1_16.c
|
Formatting adjustments and created initial file for exercise 1-17.
|
2025-09-05 18:49:44 +00:00 |
|
ex1_16_improved.c
|
Stub of an improved version of ex1_16 to allocate array sizes on the fly and support arbitrarily long input.
|
2025-08-28 23:32:07 +00:00 |
|
ex1_17.c
|
Reverted a change that erroneously removed ex1_17.c.
|
2025-09-05 18:52:32 +00:00 |
|
hello_world.c
|
Initial commit for KNR C exercises
|
2025-07-29 13:06:28 -07:00 |
|
hello_world.out
|
Initial commit for KNR C exercises
|
2025-07-29 13:06:28 -07:00 |
|
knrc-pseudowc.c
|
Nearly direct copy of a word count program from KNR C, mimicked here only so that I could compare the size of the resulting binary once compiled to my own solution, archived as ex1_10-5.c (ex1-10.5). The resulting binary, as compiled with GCC, was 136 lines long, 2 lines shorter than my own. Challenge failed :sigh:. Good exercise, though; I'll come back to this and study why later.
|
2025-08-16 02:07:42 +00:00 |