For Business
Login
Home
Assessments
Mytat Certificates
Community
Courses
Premium Courses
jobs
Practice
Upskilling
Projects
Help
Run ยป
#include
using namespace std; class MyClass { // The class public: // Access specifier void myMethod() { // Method/function cout << "Hello World!"; } }; int main() { MyClass myObj; // Create an object of MyClass myObj.myMethod(); // Call the method return 0; }