What is Hello World ?
Hello World ek simple program hota hai jo ki bas "Hello World" message screen display karata hai. Ye normally sabhi beginner ka first program hota hai jab bhi wo koi new programming language seekhte hain.
Why is Hello World Important ?
- Ye help karta hai ye check karne ke liye ki programming environment correctly set hai ya nhi.
- Ye us programming language ke basic syntex ko introduce karta hai.
- Ye ek tradition hai programming!
Examples of Hello World Program
C
#include<stdio.h>
int main(){
printf("Hello World!");
return 0;
}
C++
#include <iostream>
using namespace std;
int main() {
cout << "Hello, World!" << endl;
return 0;
}
Java
public class Main {
public static void main(String[] args) {
System.out.println("Hello, World!");
}
}
Kotlin
fun main() {
println("Hello, World!")
}
Swift
print("Hello, World!")
Python
print("Hello, World!")
JavaScript
console.log("Hello, World!");
Rust
fn main() {
println!("Hello, World!");
}
PHP
<?php
echo "Hello, World!";
?>
Go
package main
import "fmt"
func main() {
fmt.Println("Hello, World!")
}
OUTPUT Of All Programs Will Be Same : Hello, World!
Conclusion: "Hello World" program ek traditional style hai ye ensure karne ka programming environment correctly set hai ya nhi or programming language ke basic syntex ko samjhne ka.
Comments