Menampilkan "Hello world!" (OOP)
Menampilkan "Hello world!" (OOP)
#include <iostream>
using namespace std;
class HelloWorld {
public:
void tampilkan() {
cout << "Hello, World!" << endl;
}
};
int main() {
HelloWorld obj;
obj.tampilkan();
return 0;
}
Komentar
Posting Komentar