Hello world!

Here it is a simple Hello, World source code in C and C++ languages:

C Version:

#include<stdio.h>
main()
{
printf(“Hello, World!\n”);
}

C++ Version:

#include<iostream>
using namespace std;
main()  // In C/C++, double slashes (//) denote a comment, causing the compiler to ignore the rest of the line. If a return type is omitted from the main() function, the compiler assumes a default return type of int.
{
cout << “Hello, World!” << endl;
}

Leave a Comment

Your email address will not be published. Required fields are marked *

2 thoughts on “Hello world!”

Shopping Cart
Optimized by Optimole
Scroll to Top