Stuff
public cpp v1 · immutableclass card { string card_center(string); public: int value; string face;};// Centers the card face on the card string card::card_center(string face) { if (face.length > 7) face=face.substr(0,7); if (face.length % 2 == 0) face=face.substr(0,face.length/2)+" "+face.substr(face.length/2); string space=new string(' ',7-face.length); face="|"+space+face+space+"|"; delete space; return face; } this above code gives me this error...main.cpp:60: error: extra qualification 'card::' on member 'card_center'main.cpp:60: error: 'std::string card::card_center(std::string)' cannot be overloadedmain.cpp:12: error: with 'std::string card::card_center(std::string)'main.cpp:71: error: extra qualification 'card::' on member 'card'main.cpp:71: error: 'card::card(int, std::string, char)' cannot be overloadedmain.cpp:18: error: with 'card::card(int, std::string, char)'main.cpp:82: error: expected `}' at end of inputmain.cpp: In member function 'std::string card::card_center(std::string)':main.cpp:61: error: invalid use of member (did you forget the '&' ?)main.cpp:63: error: invalid use of member (did you forget the '&' ?)main.cpp:64: error: invalid use of member (did you forget the '&' ?)main.cpp:64: error: invalid use of member (did you forget the '&' ?)main.cpp:65: error: invalid use of member (did you forget the '&' ?)main.cpp:67: error: type 'struct std::string' argument given to 'delete', expected pointermain.cpp: At global scope:main.cpp:82: error: expected unqualified-id at end of input