class Hello:
def message(self):
return "Hello user!"
hello = Hello()
print(hello.message())
#include <iostream>
#include <string>
class Hello {
public:
std::string message() {
return "Hello, user!";
}
};
int main()
{
Hello hello;
std::cout << hello.message();
return 0;
}