What do you want to save?
Add Code snippet
New code examples
-
C++ 2022-02-02 21:51:57
pointer in cpp details
Every object in C++ has access to its own address through an important pointer called this pointer. The this pointer is an implicit parameter to all member functions. Therefore, inside a member function, this may be used to refer to the invoking object... Add solution -
-
-
Other 2022-01-29 04:07:09
how to insert an element from an array
int main() { int array[100], position, c, n, value; printf("Enter number of elements in array\n"); scanf("%d", &n); printf("Enter %d elements\n", n); for (c = 0; c < n; c++) scanf("%d"... Add solution -
C++ 2022-01-28 16:40:53
find a member variable in a vector of objects cpp
//Using a lambda function (only C++11 or newer) std::vector<Type> v = ....; std::string myString = ....; auto it = find_if(v.begin(), v.end(), [&myString](const Type& obj) {return obj.getName() == myString;}) if (it != v.end()) { // found... Add solution -
C++ 2022-01-26 05:51:41
what is a .cpp file
A .CPP file is a file that contains C++ code. Add solution -
Other 2022-01-24 05:20:37
PntIDNumbers
#include <iostream> #include <fstream> #include <cstdlib> #include <string> #include <sstream> #define MAX 200 using namespace std; // Function receive address of the first element of an array // Reads file contents and store... Add solution