Friday, March 3, 2017

Hello World Programme In 20+ Languages


C++

#include
int main()
{    
std::cout << "Hello,  ! ";    
return 0;
}

C#

using System; class Program {     public static void Main
(string[] args)    
{         Console.WriteLine("Helloworld!");     } }

Clipper

? "Hello World"

CoffeeScript

console.log 'Hello, world!'

Delphi

program HelloWorld; begin   Writeln('Hello, world!'); end.

HTML

Hello World!

Java

import javax.swing.JFrame; 
//Importing class JFrame
import javax.swing.JLabel; 
//Importing class JLabel public class HelloWorld
{
public static void main(String[] args) {        
JFrame frame = new JFrame();           //Creating frame      
frame.setTitle("Hi!");             
   //Setting title frame       
frame.add(new JLabel("Hello, world!"));
//Adding text to frame       
frame.pack();                         
//Setting size to smallest         frame.setLocationRelativeTo(null);  
  //Centering frame         frame.setVisible(true);           
    //Showing frame    
} }

JavaScript

document.write('Hello, world!');

jQuery

$("body").append("Hello world!");

Julia

println("Hello world!")

Logo

print [Hello, world!]

Matlab

disp('Hello, world!')

Objective-C

#import
#import
int main(void)
{    
NSLog(@"Hello, world! ");    
return 0;
}

Pascal

program HelloWorld; begin   WriteLn('Hello, world!'); end.

Perl 5

print "Hello, world! ";

Processing

void setup()
{  
println("Hello, world!");
}

Python

print "Hello, world!"

R

cat('Hello, world! ')

Ruby

puts "Hello, world!"

Swift

println("Hello, world!")
VBScript
MsgBox "Hello, World!"

Visual Basic .NET

Module Module1   
  Sub Main()      
   Console.WriteLine("Hello, world!")    
End Sub End Module

XSLT

Hello World

No comments:

Post a Comment