Pointer will randomly print it's address instead of it's pointed value, C++
问题 So I have this problem where the output prints the address of my pointer, I have no idea why this happens cuz the pointers is not modified at all Heres the code: using namespace std; class AndroideAbstracto { protected: int *vida; int *fuerza; int *velocidad; public: void setvalores(int vi, int fu, int ve) { velocidad = &ve; vida = &vi; fuerza = &fu; }; virtual void imprimir(void) = 0; }; class Androide : public AndroideAbstracto { public: void imprimir() { std::cout << "Caracteristicas del