Tag: library

The C template library

The C template library

Texture templateC of course doesn’t have generics or templates like C++ does, but I came across Gustav Lou’s C Template library this morning. It provides C equivalents to the following C++ template libraries. Each is done as a header file that you include.

deq.h -> std::deque
lst.h -> std::list
pqu.h -> std::priority_queue
que.h -> std::queue
set.h -> std::set
stk.h -> std::stack
str.h -> std::string
vec.h -> std::vector
 

The page on GitHub shows how to use libraries with an example of vector. The string equivalent library str.h would be an interesting one to see just how much of C++ string is supported.  C would still never be my language of choice for anything text heavy but if this is better than strcpy, strcat etc. I’ll happily use it.  Likewise list and vector. From memory C++ std::array is just a wrapper around the C standard array!

Single file libraries

Single file libraries

open book lot
Library image from Unsplash.com

Most days I scan the web for relevant or interesting stuff and today I found a real treasure. A website where they have curated a list of C and C++ single file libraries. That is libraries that are not multiple files but mostly one. I say mostly because there are a few with 2 or 3 files.

The bulk are in C++ but there are a large number of C/C++ and quite a number of C. All have their licensing; these are open source but licences vary a bit.

It’s worth a trawl through the List. For instance there’s an interpreter for a BASIC dialect scripting language,

A free C Book – “C Programming Notes for Professionals”

A free C Book – “C Programming Notes for Professionals”

C Notes for Professionals Book coverThis has nothing to do with my ebook and was produced entirely by the Goalkicker.com project which produces free and very professional looking ebooks, I came across it just a few days ago.

The C Programming Note for Professionals is currently 327 pages long, a 2.4 MB download. It’s nicely laid out and professionally done. I’ve only flicked through it but it looks an excellent piece of work with 63 chapters currently. You can leave your email address and they’ll notify you of any changes.

There are almost 50 ebooks in total covering topics like Android, .NET, Xamarion Forms, Perl, PHP, MySQL, PostgreSQL and may other topics. This is an excellent library.  I don’t know who is behind this project but they deserve to be bought a lot of coffees…