Skip to primary content
Skip to secondary content

C For Dummies Blog

Main menu

  • C For Dummies (home)
  • History
  • Series
  • Supplemental
  • Blog Miscellany

Author Archives: dgookin

Post navigation

← Older posts
Newer posts →

Things That Bounce (Even More exp() Function Stuff)

Posted on August 23, 2025 by dgookin
Reply

It’s time to free yourself from the math-nerd aspect of the exp() function and put it to legitimate use by animating an asterisk bouncing across the screen. Such a feat may be considered unusual for a stream-oriented programming language like C, but I find animation more interesting than math.
Continue reading →

Posted in Lesson | Leave a reply

Things That Fall (More exp() Function Stuff)

Posted on August 16, 2025 by dgookin
4

Text mode graphics were a Big Deal with computers for the longest time. C’s stream I/O didn’t stop various computer games from being developed throughout the 1970s and 1980s. And this limitation isn’t going to stop me from animating a falling ball, er, asterisk.
Continue reading →

Posted in Lesson | 4 Replies

Fun with the exp() Function

Posted on August 9, 2025 by dgookin
Reply

Deep in the crevasse of oddball math functions is one that raises Euler’s number (e) to a given power. This calculation is vital enough in programming that it sports its own function, exp(). And I would ignore this function with exuberant glee were it not for a trick someone showed me a long time ago.
Continue reading →

Posted in Lesson | Leave a reply

Your Name in Base 36 – Solution

Posted on August 8, 2025 by dgookin
Reply

My solution for this month’s Exercise didn’t require much work. What I did was to “stack overflow” the problem by pulling in functions from earlier Lessons. The only new portion of code deals with processing the input before sending the string off to the b36_decimal() function I’ve already written.
Continue reading →

Posted in Solution | Leave a reply

My “Dear Lord This Is So Boring” Dice-Rolling Game

Posted on August 2, 2025 by dgookin
Reply

Rolling seven dice over and over is how I passed time “playing” D&D. But I also played a game with the dice, one that I introduced in last week’s Lesson. That lesson’s code got things started. This Lesson finishes the project.
Continue reading →

Posted in Lesson | Leave a reply

Your Name in Base 36

Posted on August 1, 2025 by dgookin
Reply

Difficulty: ★ ★ ☆ ☆

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 →

Posted in Exercise | Leave a reply

Roll ‘dem Bones!

Posted on July 26, 2025 by dgookin
Reply

You would think that I’d be deeply into Dungeons and Dragons, but no. I can’t stand the game. I find it tedious and predictable, boring. But I did enjoy rolling all those dice. Who knew that a 20-side die is a thing — and that rolling a “nat 20” is a big deal?
Continue reading →

Posted in Lesson | Leave a reply

From Base 36 to Decimal

Posted on July 19, 2025 by dgookin
Reply

Continuing my Base 36 series, from last week’s Lesson, the base35_string() function successfully converts a decimal value into its base 36 representation. To verify that the conversion works, another function is necessary to convert base 36 strings into their decimal equivalents.
Continue reading →

Posted in Lesson | Leave a reply

From Decimal to Base 36

Posted on July 12, 2025 by dgookin
Reply

The next step in my Base 36 series is to translate a decimal value into its base 36 representation. In last week’s Lesson, code was presented to build a powers table and slice a decimal value into its base 36 components. This Lesson completes the task with a function, base36_sting() to build and output a base 36 value.
Continue reading →

Posted in Lesson | Leave a reply

The Reversing Filter – Solution

Posted on July 8, 2025 by dgookin
2

This month’s Exercise presents more than a traditional filter. Instead of input being processed and immediately output, the input must be stored. Further, the storage quantity is unknown. Therefore, to provide proper storage the code must employ an expanding buffer. This condition means that the solution relies upon the scariest aspect of C programming: pointers!
Continue reading →

Posted in Solution | 2 Replies

Post navigation

← Older posts
Newer posts →

Recent Posts

  • Heron’s Formula – Solution
  • Coding a Better stringcopy() Function
  • Heron’s Formula
  • Copying Strings
  • Finding Those Pesky Null Characters!

Recent Comments

  • dgookin on Heron’s Formula
  • Chris Webb on Heron’s Formula
  • dgookin on Heron’s Formula
  • Chris Webb on Heron’s Formula
  • dgookin on Finding Those Pesky Null Characters!

Meta

  • Log in
  • Entries feed
  • Comments feed
  • WordPress.org

Copyright © 1997-2025 by QPBC.
All rights reserved

Proudly powered by WordPress