Jim's
Tutorials

Spring 2018
course
site

C - Thu Feb 15

On hackernews today ... The cost of forsaking C | discussion

Nate Says

Interesting discussion, I'm liking the way c makes me think about programming but I'm having trouble finding good ways to practice. I wrote out a few basic sorting algorithms in c, spent awhile watching videos, visualizing them and staring at the code, then tried to wrap my mind around merge sort. I get the idea but I think I need to work with recursion a bit to really get what the code does. I think what I really need is just clear reasons and exercises to write more code.

Jim says

My first reaction to what you've submitted here is the same as what I've said to almost everything you've submitted:

Usually functions have (a) API docs i.e. inputs, outputs, and (b) implementation comments as needed. It's true that these are short fairly simple examples. But if you don't get into the habit of doing this stuff now, as your coding practice becomes ingrained, then people who you work with later - and you looking at your old code - will either do lots of extra work and/or end up starting from scratch rather than building on what you did before.

... I've uploaded C files that we worked on in class. Somewhat random but might be helpful reminders.

We talked about doing next something like

While it isn't in C, this may be a good resource :

https://cs.marlboro.college /cours /spring2018 /jims_tutorials /web_tech /c_feb15
last modified Fri April 26 2024 7:40 pm

attachments [paper clip]

  last modified size
TXT bubbleSort.c Fri Apr 26 2024 07:40 pm 592B
TXT insertion.c Fri Apr 26 2024 07:40 pm 542B
TXT jim_time.c Fri Apr 26 2024 07:40 pm 169B
TXT selection.c Fri Apr 26 2024 07:40 pm 656B