What is the equivalent of "return null" in cpp?
Hi!
I'm trying to learn c++ coming from Java.
Could someone explain to me the way this works in c++?
I have a function returning an object and if I can't construct the object I want to do what in Java would be return null.
Here is the minimal working example that I would like to get to work.
Code:
#include <string>
using namespace std;
string readObjects(string line){
return 0;
}
int main (int argc, char * const argv[]) {
readObjects(s);
return 0;
}