Browsing All posts tagged under »ansi c«

A bug that always gets me

October 21, 2012

3

This week I made an error that I already repeated at least twice in my career; it doesn’t seem to stick in my brain. I’m going to write about it here, so that maybe I will stop doing it, and maybe it will prevent the same kind of error for my readers. Let’s see if you can spot […]

C

October 18, 2011

0

I’ll probably never be as good, I’ll certainly never stop trying. The things we take for granted today are the revolutions of yesterday.

A nasty string initialization bug in C

May 31, 2011

5

Today I encountered a bug that was quite difficult to find regarding strings. In order for strings to work they must be null-terminated, and this implies that an array of characters can contain a string with a length equal to the array size minus one, because there must be space for the null character. I […]

The shoulders of Knuth

January 25, 2011

0

One of the greatest virtues that a programmer should have is humility: it allows to be non-judgmental and prone to learn. Sometimes, because of pride and self confidence, it’s difficult or unnatural to feel humble in front of a fellow student, or a coworker, or your boss, or sometimes even your teacher. But if you […]

High-level vs Low-level programming

March 27, 2009

0

Scott James Remnant explains his view on C programming versus C# or Python programming. I’d like to comment on this topic too. I feel that in theory he’s wrong: low-level programming is inefficient respect to high-level programming. But in practice I think he’s right: a software coded in a low-level language is better respect to […]

The volatile keyword

March 3, 2009

2

The volatile keyword is a feature of the C language that is not considered by new developers until they bang their head against an apparently correct code that doesn’t work, and they don’t understand why. I think it is important to know the existence of the keyword and the principles behind it in order to […]

Follow

Get every new post delivered to your Inbox.

Join 394 other followers