Difficulty: ★ ★ ☆ ☆
The only aspect of math I enjoyed in school was geometry. Trigonometry was a close second. I found the study fascinating and did well; I received a B in that class as opposed by my usual C- or D.
Continue reading
The only aspect of math I enjoyed in school was geometry. Trigonometry was a close second. I found the study fascinating and did well; I received a B in that class as opposed by my usual C- or D.
Continue reading
A few months back, this blog’s monthly Exercise was to write a filter to reverse all text input. No matter how much text floated in, the filter gobbled it all up and spewed it back in reverse order. This month’s challenge is similar, but on a smaller scale.
Continue reading
Last month, I completed my series on Base 36, which uses digits 0 through 9 and A through Z to represent values. The use of these digits means that common words can represent values in base 36. In fact, your name is a base 36 value. But what is it?
Continue reading
Filters are fun to code and useful, such as the more filter in Linux that pages text output. For this month’s Exercise, your task is to write a text reversing filter. This program is a bit more challenging than coding other types of filters.
Continue reading
I watched the film Contact a few weeks ago. The movie is about first contact with an alien civilization. It’s smart cinema, which offers that communications between species would be mathematical in nature, as math is the universal language.
Continue reading
Here is an issue that crops up often in programming, specifically when outputting data in a series: How do you separate items in the series and not make the last item look dorky? It’s tricky.
Continue reading
Loops are fun. They’re easy to learn. But not everything that repeats in a C program is constructed as a loop.
Continue reading
One of the most clever string functions is strstr(), which searches for one string within another. Because of its return value — a char pointer — it’s possible to call this function multiple times to continue searching through the string.
Continue reading
Pointers can drive C programmers mad. In fact, I’d say that evidence of this notion is that the most experienced C programmers have an air of insanity about them. To join their club, try working this month’s Exercise.
Continue reading
I think any kid learning math in school knows what a remainder is, but few understand (or are taught) what a modulus is. It obtains the remainder of one value divided by another, specifically a larger value divided by a smaller value. In C programming, the %
(modulo) operator performs this calculation. But what if the C language lacked a modulo operator?
Continue reading