Pelles C forum

C language => Beginner questions => Topic started by: jos on January 15, 2026, 08:58:58 AM

Title: Small C Programs to Learn From
Post by: jos on January 15, 2026, 08:58:58 AM
Not sure if this is the right place to put this? But here are some nice simple C programs to learn from?

https://codegnan.com/c-programming-projects/ (https://codegnan.com/c-programming-projects/)
Title: Re: Small C Programs to Learn From
Post by: Vortex on January 15, 2026, 03:28:20 PM
Hi jos,

Thanks. If you are looking for API programming sources, we can help you.
Title: Re: Small C Programs to Learn From
Post by: TimoVJL on January 15, 2026, 07:21:47 PM
theForger's Win32 API Programming Tutorial (http://winprog.org/tutorial/)

Windows API controls I (https://zetcode.com/gui/winapi/controls/)

Module 1. Your First Windows Program (https://learn.microsoft.com/en-us/windows/win32/learnwin32/your-first-windows-program)
Title: Re: Small C Programs to Learn From
Post by: jos on January 16, 2026, 12:47:25 PM
Thanks, have gone through theForger, Windows API etc. Scan the net and try to read and understand code I find in C.

I feel like I'm making progress (slowly) when I start from scratch. But trying to use routines or other general programs I get so many errors and warnings! I guess my knowledge of pragma etc. limits me. But it will come eventually...

I have new problems with PDFio, trying to test and compile a file in the library example: pdf2text. (The example I got earlier works just fine?)

PS. have upgraded to Pellesc 13.00.9
Title: Re: Small C Programs to Learn From
Post by: TimoVJL on January 16, 2026, 01:08:33 PM
put
#ifndef __POCC__
typedef __int64 ssize_t;        // POSIX type not present on Windows... @private@
#endif
or#ifndef __POCC__
typedef size_t ssize_t;
#endif
it should be in <sys/types.h> without any ifdefs

before headers to pdf2text.c
of mofify pdfio.h and put it there
also compile with -Go Define compability names
Title: Re: Small C Programs to Learn From
Post by: jos on January 16, 2026, 04:06:59 PM
Many thanks again,
Now it works! I'm only using PelleC at the moment, is there a list of all the must-"haves" or not use when using __POCC__? Is there any site to read?
Title: Re: Small C Programs to Learn From
Post by: Vortex on January 16, 2026, 10:01:48 PM
Hi jos,

In the manual supplied with Pelles C ( \PellesC\Bin\Help\help0009.chm ) search for this : Predefined preprocessor symbols (POCC)