Tag: projects

Ideas for C Projects when learning it

Ideas for C Projects when learning it

Image by Gordon Johnson from Pixabay

Personally I always found the best way for me to learn a new language was to take an existing program- maybe something 500 lines or so long and completely convert it to the new language. It forces you to learn how to do things like string and file handling, organising the program, getting input and producing output and so on.

But having seen requests (on the C programming subreddit) for ideas to help someone apply their newly learnt knowledge, here’s a list of ideas of projects that are doable ion C. Nothing silly like database or operating systems!

  1. A simple calendar. Enter a date and show the month. Bonus points if you can use past dates and show the day that a date is on. Hint. Look up Zeller’s Congruence.
  2. Implement John Conway’s Game of Life. A cellular automaton that can be quite fascinating.
  3. Have a go at a Snake Game.  No cheating by looking at the Games Sources (link above on the top menu).
  4. Solve the 8 Queen’s problem. Put 8 queens on a chessboard so no piece can see and attack another.
  5. Create a maze generator. Make sure it includes at least one path from start to finish.

If you get through that lot, you go up a level and should look at this list.

A collection of app ideas

A collection of app ideas

Image by pencil parker from Pixabay

Now this isn’t a bad thing. On GitHub, someone has built a collection of ideas if you are looking to develop something to further your skills. There always seems top be something about November as a month to do things, whether it’s growing a moustache (“Movember), Writing a 50,000 word novel (NaNoWriMo) or this.

These are in three tiers with 35 Tier 1 “Developers in the early stages of their learning journey. Those who are typically focused on creating user-facing applications.”,  the same number at Tier 2 “Developers at an intermediate stage of learning and experience. They are comfortable in UI/UX, using development tools, and building apps that use API services.” and 20 at Tier 3. “Developers who have all of the above, and are learning more advanced techniques like implementing backend applications and database services.”

If you finish all those, you’ll have done 90 projects. The last 20 of course being the most complex and including such things as a Discord Bot that plays Battleships, an Elevator simulator, a fats food restaurant simulator and the like. There’s no platform or programming language specified.

I’ve seen elevator simulators done before. Single elevator or multiple ones and for varying numbers of storeys.  Optimising the algorithm to minimise the waiting time is interesting and not always obvious. Do you have elevators wait wat floors when not in use or do they sit on the ground floor.

The author of this Florin pop has also completed 100 projects in 100 days if you fancy a challenge.

Want to learn C by doing projects?

Want to learn C by doing projects?

Image by FelixMittermeier from Pixabay

This site on Github has lots of interesting projects that will help you improve your C programming ability.

Whether it’s  a chess engine, a sudoku solver, space invaders clone,  tic-tac-toe (noughts and crosses for us Brits!), Othello, program a text adventure plus a lot of non games stuff as well.

I’ve added this to the C code Links page.


Or do you fancy learning how to write your own virtual Machine in C? Authors Justin Meiners and Ryan Pendleton have crafted a 14 part tutorial that will teach you how to write a VM that can run assembly language programs.