Research on "Hello World" in programming. Why is it so famous?



Download 15.73 Kb.
Date28.05.2018
Size15.73 Kb.
#51772
Marielou Kirsten Lanzar
Research on "Hello World" in programming. Why is it so famous?

Well basically, "hello" is the typical word that can be heard from someone if it is your first time to meet. As for my perspective, a program is working and alive if the programmer, as a person, would be able to see the word that he would utter if he is talking to someone. The word "world" is just a correspondent that indicates that the program was made out of a computer.

From my research, it is said to be famous because of Brian Kernighan. He wrote "hello world" program as part of the documentation for the BCPL programming language developed by Martin Richards. BCPL was used while C was being developed at Bell Labs a few years before the publication of Kernighan and Ritchie's C book in 1972. From then onwards,  it is by tradition often used to illustrate to beginners the most basic syntax of a programming language.

Research and compare how "Hello World" is implemented in C, Assembly, Cobol, Visual Basic and Python.

Visual Basic, C Programming Language and Python have more similarities in format than the Assembly and COBOL language. To print the text C uses printf, Visual Basic uses a message box and Python just uses print. For Assembly and COBOL, they use a longer syntax to display “Hello World”.
COBOL:

*****************************

IDENTIFICATION DIVISION.

PROGRAM-ID. HELLO.

ENVIRONMENT DIVISION.

DATA DIVISION.

PROCEDURE DIVISION.

MAIN SECTION.

DISPLAY "Hello World!"

STOP RUN.

****************************
ASSEMBLY:

.486p


.model flat,STDCALL

include win32.inc

extrn MessageBoxA:PROC

extrn ExitProcess:PROC



.data

HelloWorld db "Hello, world!",0

msgTitle db "Hello world program",0

.code



Start:

push MB_ICONQUESTION + MB_APPLMODAL + MB_OK

push offset msgTitle

push offset HelloWorld

push 0

call MessageBoxA

push 0

call ExitProcess

ends


end Start

VISUAL BASIC:

Module Hello

Sub Main()

MsgBox("Hello, World!") ' Display message on computer screen.

End Sub 


End Module

PYTHON:


print "Hello, World!"

C:

#include



#include

int main(void)



{

printf("Hello, world!\n");



return EXIT_SUCCESS;

}

Download 15.73 Kb.

Share with your friends:




The database is protected by copyright ©ininet.org 2024
send message

    Main page