فهرست مثال‌های برنامه Hello World کیست؟ توضیح بده.
یک برنامه Hello World، یک برنامهٔ رایانه‌ای ساده است که جمله «!Hello, world» را در صفحۀ نمایش چاپ می‌کند. معمولاً ساده‌ترین برنامهٔ ممکنی است که می‌توان در زبان‌های برنامه‌نویسی مختلف نوشت و یک عمل سنتی است که بسیاری از برنامه‌نویسان که قصد آموزش یک زبان برنامه‌نویسی را دارند، توصیه به نوشتن آن می‌کنند که اولین قدم در یادگیری آن زبان برنامه‌نویسی است. بیشتر از این برنامه برای مقایسه نحو دو زبان مختلف استفاده می‌شود. در زیر فهرستی از برنامه‌های Hello World مرسوم در ۹۱ زبان برنامه‌نویسی آمده‌است.آباپ.REPORT HELLOWORLD.WRITE 'Hello, world!'.اکشن‌اسکریپت.trace ("Hello, world!");یا:package com.example import flash.text.TextField; import flash.display.Sprite; public class Greeter extends Sprite public function Greeter() var txtHello:TextField = new TextField(); txtHello.text = "Hello, world!"; addChild(txtHello);ایدا.with Ada.Text_IO;procedure Hello_World is use Ada.Text_IO;begin Put_Line("Hello, world!");end;Adventure Game Studio Script.Display("Hello, world!");یا:DrawingSurface *surface = Room.GetDrawingSurfaceForBackground();surface.DrawString(0, 100, Game.NormalFont, "Hello, world!");surface.Release();الگول.&lt;syntaxhighlight&gt;BEGIN DISPLAY ("Hello, world!");END.&lt;/syntaxhighlight&gt;ALGOL 68.print("Hello, world!")Amiga E.&lt;syntaxhighlight&gt;PROC main() WriteF('Hello, world!')ENDPROC&lt;/syntaxhighlight&gt;ای‌پی‌ال.'Hello, world'Assembly Language — MOS Technology 6502, CBM KERNEL. A_CR = $0D ;carriage return BSOUT = $FFD2 ;kernel ROM sub, write to current output device LDX #$00 ;starting index in.X register LOOP LDA MSG,X ;read message text BEQ LOOPEND ;end of text JSR BSOUT ;output char INX BNE LOOP ;repeat LOOPEND RTS ;return from subroutine MSG.BYT 'Hello, world!',A_CR,$00اسمبلی x86 داس..model tiny.codeorg 100hmain proc mov ah,9 ; Display String Service mov dx,offset hello_message ; Offset of message (Segment DS is the right segment in.COM files) int 21h ; call DOS int 21h service to display message at ptr ds:dx retn ; returns to address 0000 off the stack ; which points to bytes which make int 20h (exit program)hello_message db 'Hello, world!$'main endpend mainزبان اسمبلی x86 ویندوز ۳۲ بیتی..486p.model flat,STDCALLinclude win32.incextrn MessageBoxA:PROCextrn ExitProcess:PROC.dataHelloWorld db "Hello, world!",0msgTitle db "Hello world program",0.codeStart: push MB_ICONQUESTION + MB_APPLMODAL + MB_OK push offset msgTitle push offset HelloWorld push 0 call MessageBoxA push 0 call ExitProcessendsend Startزبان اسمبلی - x86-64 لینوکس، ای‌تی‌اندتی..section .rodatastring:.ascii "Hello, world!\n\0"length:.quad. -string #Dot = 'here'.section .text.globl _start #Make entry point visible to linker_start:movq $4, %rax #4=writemovq $1, %rbx #1=stdoutmovq $string, %rcxmovq length, %rdxint $0x80 #Call Operating Systemmovq %rax, %rbx #Make program return syscall exit statusmovq $1, %rax #1=exitint $0x80 #Call System Againزبان اسمبلی - Z80. EQU CR = #0D ; carriage return EQU PROUT = #xxxx ; character output routine LD HL,MSG ; Point to message PRLOOP LD A,(HL) ; read byte from message AND A ; set zero flag from byte read RET Z ; end of text if zero JSR PROUT ; output char INC HL ; point to next char JR PRLOOP ; repeat MSG DB "Hello, world!",CR,00AutoHotkey.Msgbox, Hello, world!Traytip, Hello, world!AutoIt.Msgbox(64, "", "Hello, world!")بیسیک.PRINT "Hello, world!"Batch File.@echo Hello, world!BCPL.&lt;syntaxhighlight&gt;GET "LIBHDR"LET START() BE$(WRITES("Hello, world!*N")&lt;/syntaxhighlight&gt;+++ +++++ initialize counter (cell #0) to .brainfuck.[ use loop to set the next four cells to 70/100/30/10 &gt; +++++ ++ add 7 to cell #1 &gt; +++++ +++++ add 10 to cell #2 &gt; +++ add 3 to cell #3 &gt; + add 1 to cell #4 ««- decrement counter (cell #0)&gt; ++. print 'H'&gt; +. print 'e'+++ ++. print '.. print 'l'+. print '.&gt; ++. print ' '«+++++ +++++ +++++. print 'W'&gt;. print 'o'+. print '.---- -. print 'l'---- ---. print 'd'&gt; +. print '!'&gt;. print '\n'سی.void main() printf("Hello World!");سی++.using namespace std;int main() cout « "Hello, world!" « endl; return 0;سی شارپ.using System;class Program public static void Main() Console.WriteLine("Hello, world!"); Console.ReadKey(true);Casio BASIC."HELLO, WORLD!"Common Intermediate Language..method static void Main().entrypoint.maxstack 1 ldstr "Hello, world!" call void [mscorlib]System.Console::WriteLine(string) call string[mscorlib]System.Console::ReadKey(true) pop retColdFusion Markup Language (CFML).CF Script:&lt;cfscript&gt; variables.greeting = "Hello, world!"; WriteOutput(variables.greeting);&lt;/cfscript&gt;CFML Tags:&lt;cfset variables.greeting = "Hello, world!"&gt;&lt;cfoutput&gt;#variables.greeting#&lt;/cfoutput&gt;کلوژر.نسخه ی پیشانه ای (کنسولی):نسخه ی gui:کوبول. IDENTIFICATION DIVISION. PROGRAM-ID. HELLO-WORLD. PROCEDURE DIVISION. DISPLAY 'Hello, world!'. STOP RUN.دی.import std.stdio;void main() writeln("Hello, world!");دارت.main() print('Hello, world!');DCL.WRITE SYS$OUTPUT "Hello, world!"دلفی.begin Writeln('Hello, world!');end.Erlang.io:format("~s~n", ["Hello, world!"])F.printfn "Hello, world!"Falcon. printl("Hello, world!")or&gt; "Hello, world!"Forth.." Hello, world! "فورترن.program hello write (*,*) 'Hello, world!'end program helloprogram hello print *, 'Hello, world!'end program helloOR (FORTRAN 77 and prior) PROGRAM HELLO PRINT *, 'Hello, world!' ENDGame Maker Language.str='Hello, world!'//Using the show_message() function:show_message(str);//Using the draw_text() function:draw_text(0,0,str);Go.package mainimport "fmt"func main() { fmt.Println("Hello, world!")Groovy.println "Hello, world!"Haskell.main = putStrLn "Hello, world!"HOP. (&lt;HTML&gt; (&lt;HEAD&gt; (&lt;BODY&gt;"Hello, world!")))اچ‌تی‌ام‌ال.&lt;!DOCTYPE html&gt;&lt;html&gt;&lt;body&gt;Hello, world!&lt;/body&gt;&lt;/html&gt;IDL.print, "Hello, world!"endIo. "Hello, world!" printlnجی. 'Hello, world!'جاوا.public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, world!");جاوااسکریپت.To write to an HTML document:document.write('Hello, world!');To display an alert dialog box:alert('Hello, world!');To write to a console/debugging log:console.log('Hello, world!');Using Mozilla's Rhino:print('Hello, world!');Using Windows Script Host:WScript.Echo("Hello, world!");Kotlin.package hellofun main(args: Array&lt;String&gt;) { println("Hello, world!")Logo.print [Hello, world!]لوآ.print("Hello, World!")M4.&lt;syntaxhighlight&gt;Hello, world!&lt;/syntaxhighlight&gt;Malbolge.&lt;syntaxhighlight&gt;(=&lt;`#9]~6ZY32Vx/4Rs+0No-&amp;Jk)"Fh}|Bcy?`=*z]Kw%oG4UUS0/@-ejc(:'8dc&lt;/syntaxhighlight&gt;Mathematica.Print["Hello, world!"]Maple.print(`Hello, world!`);متلب.disp('Hello, world!')mIRC Script.&lt;syntaxhighlight&gt;echo -a Hello, world!&lt;/syntaxhighlight&gt;MUMPS.main() write "Hello, world!" quitOberon.MODULE Hello; IMPORT Out;BEGIN Out.String("Hello, world!"); Out.LnEND Hello.Obix.&lt;syntaxhighlight&gt;system.console.write_line ("Hello, world!")&lt;/syntaxhighlight&gt;Objective-C.int main(void) printf("Hello, world!\n"); return 0;Otherwise (by gcc on pre-OpenStep/Apple Object based runtime):@interface Hello: Object- (void) say;@end@implementation Hello- (void) say { printf("Hello, world!\n");@endint main() { Hello *hello = [Hello new]; [hello say]; [hello free]; return 0;Pre-Modern (post-1994 OpenStep based Foundation APIs:@interface Hello:NSObject- (void) say;@end@implementation Hello- (void) say { NSLog(@"Hello, world!");@endint main(int argc, char *argv[]) NSAutoreleasePool *p = [[NSAutoreleasePool alloc] init]; Hello *hello = [Hello new]; [hello say]; [hello release]; [p release]; return 0;Modern (llvm, ARC memory management):@interface Hello:NSObject- (void) say;@end@implementation Hello- (void) say { NSLog(@"Hello, world!");@endint main(int argc, char *argv[]) @autoreleasepool {; [[Hello new] say]; return 0;OCaml. print_endline "Hello, world!"Opa.A "hello world" [[سرور وب]]:Server.start(Server.http, { title: "Hello, world!", page: function() { &lt;&gt;Hello, world!&lt;/&gt; } })Oriel.&lt;syntaxhighlight&gt;MessageBox(OK, 1, INFORMATION, "Hello, world!", "Oriel Says Hello", ResponseValue)&lt;/syntaxhighlight&gt;پاسکال.program HelloWorld;uses crt;begin WriteLn('Hello, world!');end.Pawn.main() print("Hello, world.");Perl 5.print "Hello, world!";Oruse v5.10;say 'Hello, world!';پی‌اچ‌پی.&lt;?php echo 'Hello, world!' ?&gt;or&lt;?php print 'Hello, world' ?&gt;or&lt;?= 'Hello, world!' ?&gt;PL/SQL.SET SERVEROUTPUT ON;BEGIN DBMS_OUTPUT.PUT_LINE('Hello, world!');END;PowerShell.Write-Host "Hello, world!"Prolog.main:- write('Hello, world!'), nl.پایتون ۲.print "Hello, world!"پایتون ۳.print("Hello, world!")Pythonect."Hello, world!" -&gt; printR.cat('Hello, world!\n')Racket.Trivial "hello world" program:"Hello, world!"Running this program produces codice_1. More direct version:A "hello world" [[سرور وب]] using Racket's codice_2 language:REXX.say Hello, world!RPL.«"Hello, world!" MSGBOX»RTL/2.&lt;syntaxhighlight&gt;TITLE Hello, world!;LET NL=10;EXT PROC(REF ARRAY BYTE) TWRT;ENT PROC INT RRJOB(); TWRT("Hello, world!#NL#"); RETURN(1);ENDPROC;&lt;/syntaxhighlight&gt;روبی.puts "Hello, world!"یا بدون پرش به سر خط:print "Hello, world!"Rust. fn main() { println!("Hello, world!");Scala.object HelloWorld extends App { println("Hello, world!")Shell.echo Hello, world!Simula.Begin OutText ("Hello, world!"); Outimage;End;Smalltalk.Transcript show: 'Hello, world!'.SNOBOL. OUTPUT = 'Hello, world!'ENDSpeakeasy.به صورت عبارات تعاملی(interactive):&lt;syntaxhighlight&gt;"Hello, world!"&lt;/syntaxhighlight&gt;به عنوان برنامه:&lt;syntaxhighlight&gt;program hello "Hello, world!"end&lt;/syntaxhighlight&gt;SQL.SELECT 'Hello, world!' FROM DUMMY; -- DUMMY is a standard table in SAP HANA.SELECT 'Hello, world!' FROM DUAL; -- DUAL is a standard table in Oracle.SELECT 'Hello, world!' -- This will work in SQL Server.Smalltalk.Transcript show: 'Hello, world!'.Stata.display "Hello, world!"Tcl.puts "Hello, world!"TI-BASIC.Disp "Hello, world!"UnrealScript.&lt;syntaxhighlight&gt;Log("Hello, world!");&lt;/syntaxhighlight&gt;Vala.void main () print ("Hello, world!\n");Visual Basic. MsgBox "Hello, world!"Visual Basic.NET.Module Module1 Sub Main() Console.WriteLine("Hello, world!") End SubEnd Module'non-console example:Class Form1 Public Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs) Handles Me.Load() MsgBox("Hello, world!") End SubEnd ClassWhitespace. S S S T S S T S S S LT LS S S S S T T S S T S T LT LS S S S S T T S T T S S LT LS S S S S T T S T T S S LT LS S S S S T T S T T T T LT LS S S S S T S T T S S LT LS S S S S T S S S S S LT LS S S S S T T T S T T T LT LS S S S S T T S T T T T LT LS S S S S T T T S S T S LT LS S S S S T T S T T S S LT LS S S S S T T S S T S S LT LS S S S S T S S S S T LT LS S LLLپیوند به بیرون.[[رده:برنامه‌نویسی]][[رده:مقاله‌های با مثال کد سی شارپ]]