Write a program that uses the function isPalindrome given in Example 6-6 (Palindrome). Test your program on the following strings: madam, abba, 22, 67876, 4
struct B { virtual void bar () {} virtual void foo () { bar(); } }; struct D : B { virtual void bar () {} virtual void foo () {} }; Now we call foo()
What is the difference between definition and instantiation? Sub-question: Are "variable definition" and "variable instantiation" the same? int x; The above
I'm just curious about what is going on when trying to add a char to a string. Initially, I thought it would work like a concatenation but it didn't: cout<&l
I'm not a c++ expert but I've serialized things a couple of times in the past. Unfortunately this time I'm trying to serialize a class which contains an std::st
I made a file hi.cpp and I wrote the command given below: #include <iostream> using namespace std; int main () { cout << "Hello World! "; cout
I'm currently playing around with conan. So I've created two small project: The first project is a small library "fcdk": https://github.com/lmarzull/fcdk/tree/d
Say you have a string which is provided by the user. It can contain any kind of character. Examples are: std::string s1{"hello world"); std::
By this question I am also trying to understand fundamentals of C++, as I am very new to C++. There are many good answers to problem of sorting a vector/list of
It has been possible to build apps for Arduino and Teensy written in Rust for a while. You can find lists of peripheral libraries ( https://github.com/rust-embe
How can be an array of double (1D) stored using protocol buffer? What about multi-dimensional (2D or 3D) dense arrays?
Is the size of a pointer the same as the size as the type it's pointing to, or do pointers always have a fixed size? For example... int x = 10; int * xPtr = &a
How can I link OpenNI (libOpenNI2.so) at run time to my C++ program? This question/answer is most relevant to my question. I followed it and prepared the follow
I've been trying to setup my VSCode to work with Clangd as a LSP server for my Cpp projects. I've successfully established basic functions such as the LSP itsel
I am currently trying to connect c++ with nodejs project using node-gyp. My current problem is that i have a 32 bit library file and a 64 bit library file. My c
I am using std::atomic<unsigned int> in my program. How can I print its value using printf? It doesn't work if I just use %u. I know I can use std::cout,
I am getting the following import error when I am trying to run a Python script in a conda environment (squad) azada@scholar-fe00:~/Desktop/Toy-Problem-Team-2 $
I have a number of algorithms for community detection on graphs that I want to now visualise them. This visualisation requires me to 'hijack' these algorithms
To overcome alignment issues, I need to memcpy into a temporary. What type should that temporary be? gcc complains that the following reinterpret_cast will br
When I try to determine end of file with function feof(FILE *), I find it does not work as I expected: an extra read is required even if the stream does end. E.