About 23,500,000 results
Open links in new tab
  1. What does '&' do in a C++ declaration? - Stack Overflow

    I am a C guy and I'm trying to understand some C++ code. I have the following function declaration:

  2. What does the "::" mean in C++? - Stack Overflow

    Sep 9, 2023 · What does this symbol mean? AirlineTicket::AirlineTicket ()@PaulR Not everyone who arrives upon this question is looking to learn C++. I, for example, just happened to be …

  3. How to use the PI constant in C++ - Stack Overflow

    Nov 13, 2009 · I want to use the PI constant and trigonometric functions in some C++ program. I get the trigonometric functions with include <math.h>. However, there doesn't seem to be …

  4. c++ - Inheriting constructors - Stack Overflow

    Constructors are not inherited. They are called implicitly or explicitly by the child constructor. The compiler creates a default constructor (one with no arguments) and a default copy constructor …

  5. Run C++ in command prompt - Windows - Stack Overflow

    Syntax is just gcc my_source_code.cpp, or gcc -o my_executable.exe my_source_code.cpp. It gets more complicated, of course, when you have multiple source files (as in implementation; …

  6. How can I get the list of files in a directory using C or C++?

    How can I determine the list of files in a directory from inside my C or C++ code? I'm not allowed to execute the ls command and parse the results from within my program.

  7. What is the C++ function to raise a number to a power?

    In C++ the "^" operator is a bitwise XOR. It does not work for raising to a power. The x << n is a left shift of the binary number which is the same as multiplying x by 2 n number of times and …

  8. parsing - Parse (split) a string in C++ using string delimiter ...

    see this question implement reading files and splitting strings with c++20.

  9. Callback functions in C++ - Stack Overflow

    Note: Most of the answers cover function pointers which is one possibility to achieve "callback" logic in C++, but as of today not the most favourable one I think. What are callbacks (?) and …

  10. Iterate through a C++ Vector using a 'for' loop - Stack Overflow

    Oct 3, 2012 · I am new to the C++ language. I have been starting to use vectors, and have noticed that in all of the code I see to iterate though a vector via indices, the first parameter of …