• home

Tutorials

  • C++ Language: Learn this versatile and powerful programming language. Includes detailed explanations of pointers, functions, classes and templates, among others...
  • Reference

    Description of the most important classes, functions and objects of the Standard Language Library, with descriptive fully-functional short programs as examples.
    Browse the C++ Reference

    Articles

    User-contributed articles, organized into different categories.
    You can contribute your own articles!
    Browse Articles

    Latest forum activity:

    by colt
    Simple tga writer not working correctly.   [Beginners]
     
    Hi. I did write code to write a simple tga file format file. Unfortunately, it does not seem to work as expected. The resulting image is always black, not ma...
    [2 replies] Last: You are writing near black pixels. Try 255, 0, 0 !!! Also, you are wr... (by DizzyDon)
    Namespace std not recognized in public API.h for shared library (1,2)   [Beginners]
     
    It has been quite a while since I was working intermittently on my project to write a C++ shared library for Basex. I finally managed to create a working combin...
    [21 replies] Last: smart pointers are used as an 'owning' pointer. They 'own' the allocat... (by seeplus)
    order of importing does affect the outcome!   [General C++ Programming]
     
    Reading about C++ 20 modules we find the assertion that the order of importing modules does not matter, and this is always compared with #including headers. I ...
    [1 reply] : [quote=JUANDENT]To illustrate consider module a1 that declares class V... (by Peter87)
    subclass does not deduce template argument in class with using std::vector<T>::vector   [General C++ Programming]
     
    Hi, I have this subclass of std::vector template<typename T> class Vec : public std::vector<T> { public: using std::vector<T>::vector; // use...
    [3 replies] Last: The class needs to be declared with 2 parameters like std::vector! Tha... (by JUANDENT)
    How do i get and set the theme colors?   [Windows Programming]
     
    How can I apply the colors chosen in the theme by the user, so that my colors overlap with the windows colors. I was thinking of this api GetSysColor, GetThe...
    [1 reply] : The WinAPI has a header file for getting and setting theme related inf... (by George PlusPlus)
    Unlock mutex when returning   [General C++ Programming]
     
    The back-end of my application executes a command with _popen and passes the output to the front-end. void Loader::LoadBuffer(const std::string& arg) { ...
    [2 replies] Last: Whoops you're right, thanks I'll make bufferLoaded atomic. As for out... (by LsDefect)
    how to read a single character as with getchar but in C++?   [General C++ Programming]
     
    Hi, in C one could read a single character from the keyboard with functions like getc() or getchar(). What is the equivalent in C++? streams use buffered inp...
    [8 replies] Last: in C one could read a single character from the keyboard with functio... (by seeplus)
    Segmentation fault (core dumped)   [Beginners]
     
    Hi, I get strange segfault error when working with hierarchy of c programs (3 stages) I can give a link to the sources, but first i will describe the issue: i ...
    [6 replies] Last: Thanks folks, the error was due to a buffer overflow of char array I ... (by Jonathan100)
    Strange arithmetic conversions   [General C++ Programming]
     
    Stroustrup states in C++ Programming Language 4th edition page 271 that the result of converting an unsigned integer to a signed one of possibly larger size imp...
    [5 replies] Last: This is one of the reasons why .ssize()/std::ssize was introduced to g... (by seeplus)
    Expectations   [Lounge]
     
    Looking for feedback to sanity check my expectations of junior and not-so-junior C++ developers. Currently wondering how things have changed since I started in ...
    [10 replies] Last: I distinctly remember two professors I enjoyed, both were for English ... (by zapshe)