Modern C Cheat Sheet Pdf
In case you haven t encountered them regular expressions are a powerful way of searching and manipulating strings.
Modern c cheat sheet pdf. The goal is to give a concise overview of basic modern c c 14. The cheatsheet focus is both on the language as well as common classes from the standard library. C for dummies by stephen davis. New user defined literals for standard library types including new built in literals for chrono and basic string these can be constexpr meaning they can be used at compile time.
This cheat sheet covers all of these. Modern c language and library features. C reference card c data types data type description bool boolean true or false char character a b etc char character array c style string if null terminated string c string from the stl int integer 1 2 1 1000 etc long int long integer float single precision floating point double double precision floating point. The stl algorithm cheat sheet that i wrote on github is meant to have a very short description of each algorithm and provide 2 5 lines of example code showing how the algorithm is used and what gets modified produced as a result.
Some uses for these literals include compile time integer parsing binary literals and imaginary number literals. A good knowledge base. Jul 17 2012 i thought about creating a cheatsheet for the c 11 regex library for a long time and i finally sat down and made it over the last few days. Based on phillip m.
C quick reference c cheatsheet. Many of these descriptions and examples come from various resources see acknowledgements section summarized in my own words. The example is not valid c 17 it doesn t compile on g 7 trunk. Duxbury s c cheatsheet and edited by morten nobel jørgensen.
C quick reference preprocessor comment to end of line multi line comment include stdio h insert standard header file include myfile h insert file in current directory define x some text replace x with some text define f a b a b replace f 1 2 with 1 2. Understanding and coding in c is easier when you know the declaration expressions and operators to perform calculations. C for dummies cheat sheet for dummies author.