r/cprogramming • u/Longjumping_Beyond80 • Mar 02 '26
Project for a new C programmer
Hello everyone, I'd like to know what was your first project when you started out C and what would you suggest a newbie as a first project? Excited to hear your answers:) You could also tell about your experience or how long you've been doing it, your successes with it, anything you want to mention you can mention it. Thank you!
10
Upvotes
13
u/EfficientSpend2543 Mar 02 '26
Built a shell from scratch. At the time I just recently finished my C course in college, so I wasn't good enough to make a functional shell. I only made cd and pwd myself, then just ran everything else through "bash -c". Pipes, redirection, history etc. was non-existent.
Nevertheless it was a great, though confusing and tedious, learning experience. It became my segway into the amazing C standard library as well as Linux.
I'd definitely recommend it.
4
u/zhivago Mar 02 '26
You might want to try writing a http 0.9 web server.
They're very simple.
5
u/Paul_Pedant Mar 02 '26
The company I worked for in 1980 bought 1,200 Perq graphic office workstations (from Three Rivers Corp), who delivered the hardware, then failed to deliver the promised OS, and canned the whole project.
My company did a deal to get some pre-release of Bell Labs Unix, and one guy to advise our UK team.
I got a two-week C course (I already had ten years of mainframe assembler, COBOL etc and two years of minicomputer assembler). My first project was to port the Bell Labs Unix onto a graphics machine with incomplete hardware specs. It went better than you might expect.
1
u/bearheart Mar 02 '26
I don’t remember. It was 1974 and it was probably something like a calculator for a line printer
1
u/KC918273645 Mar 05 '26
Write a simple software 3D renderer which rotates 3D cube in realtime on screen.
3
u/Real_Dragonfruit5048 Mar 02 '26
Build something simple and fun in C that interests you. Simple and fun are subjective, but what about these?
- Implementing a useful data structure in C, like a hashtable or a fast queue
- Creating a primitive virtual machine (doesn't need to be complete)
- Programming a microcontroller in C
- Creating a simple (and opinionated) template for C projects (I have a template for my C projects: https://github.com/habedi/template-c-project)
2
u/rphii_ Mar 02 '26
Learning what if/else are, switch, getting user input and what strings are, ...
Recently I found this page: https://codingchallenges.fyi/ I think it has many great programming ideas!
2
u/justaddlava Mar 02 '26
I made an interactive Conway's Game of Life using ncurses. It was a blast.
2
u/Specific-Housing905 Mar 02 '26
I started with simple games like tic-tac-toe and rock-paper-scissor.
2
u/bd1223 Mar 02 '26
In the 1980's I was working in a radar signal processing group, and just starting to learn C on my own. I developed over a fairly long period of time a set of programs to extract radar signal data from recordings and generate radar images of ships. Got a lot of experience with multidimensional arrays, pointers, and just good programming techniques in general.
Find something useful that interests you. I personally enjoy working with embedded systems, real-time signal processing, etc.
2
u/ninhaomah Mar 02 '26
A simple guess the number is good enough in any language.
It has input , loop , if-else , print.
1
u/roopjm81 Mar 02 '26
Writing a program to read in a file of numbers and calculate the standard deviation was a huge turning point for me.
Then it was a reverse polish notation calculator
1
u/IamNotTheMama Mar 02 '26
My first C project was a Chiropractic Practice Management System. This was my first job out of school. Things got harder after that.
1
u/El_Kasztano Mar 03 '26
You could try to implement a simple Base64 encoder/decoder. It's fascinating how you can convert an array of bytes to plain ASCII text and vice versa.
1
u/ProfessionalRun2829 Mar 04 '26
My first project was in Sinclair Basic and it was a breakout text based type of game. Useful for creating loops and if then else constructs.
1
u/Noisy88 Mar 04 '26
I remember one of my first C assignments. We had to write a program that would write a .bmp file containing a graph with numbered axis and some random plotted formula.
1
u/Norse_By_North_West Mar 06 '26
Mine was a graphics library. Helped me a lot as far as understanding pointers and memory use.
Memcpy is the bomb.