hello world!!! в консоль
Приведите пример, как вывести в консоль Hello, World!!! на любом языке.
Ответы (21 шт):
Автор решения: RomanR
→ Ссылка
Python
print("Hello, World!!!")
Это самый бесполезный вопрос из вообще всех возможных
Автор решения: entithat
→ Ссылка
Java
public class Main {
public static void main(String[] args) {
System.out.println("Hello, world!!!");
}
}
Автор решения: Danis
→ Ссылка
Python 3
print("Hello, World!!!")
Python 3
import sys
sys.stdout.write("Hello, World!!!\n")
python 2
print "Hello, World!!!"
Java
public class Main {
public static void main(String[] args) {
System.out.println("Hello, world!!!");
}
}
Javascript
console.log("Hello, World!!!")
c++
#include<iostream>
int main()
{
std::cout << "Hello, World!!!";
}
C#
using System;
namespace Sample
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Hello World!!!");
}
}
}
C
#include <stdio.h>
int main(void)
{
puts("Hello, World!!!");
}
SQL, PL/SQL Oracle
select 'Hallo, world!!!' output from dual
/
OUTPUT
---------------
Hallo, world!!!
exec dbms_output.put_line ('Hallo, world!!!')
Hallo, world!!!
Brainfuck
-[------->+<]>-.-[->+++++<]>++.+++++++..+++.[->+++++<]>+.------------.---[->+++<]>.-[--->+<]>---.+++.------.--------.-[--->+<]>...
x86 ASM
org 0x100 ; .com files always start 256 bytes into the segment
; int 21h is going to want...
mov dx, msg ; the address of or message in dx
mov ah, 9 ; ah=9 - "print string" sub-function
int 0x21 ; call dos services
mov ah, 0x4c ; "terminate program" sub-function
int 0x21 ; call dos services
msg db 'Hello, World!!!', 0x0d, 0x0a, '$' ; $-terminated message
Go
package main
import "fmt"
func main() {
fmt.Println("Hello, World!!!")
}
R
print("Hello, World!!!")
AWK
$ awk --assign=var="Hello, World!" 'BEGIN { print var; }'
Hello, World!
Pascal
program HelloWorld;
begin
writeln('Hello, World!!!');
end.
GNU Fortran
program hello
print *, 'Hello, World!'
end program hello
$ gfortran hello.f95 -o hello
$ ./hello
Hello, World!
PHP
<?php echo 'Hello, World!!!'; ?>
PixiLang
aaa:
print("Hello, World!!!")
frame(0)
goto aaa
Tcl
puts {Hello, world!}
Ruby
puts "Hello, world!"
Bash & Batch
echo Hello, world!
Stuck
Данный список был составлялся с помощью следующих участников:
- Python 3
- Javascript
- C#
- Java
- PHP
- SQL, PL/SQL Oracle
- AWK
- GNU Fortran
- Tcl
- Ruby
- Bash & Batch
- Stuck
- C++
- C
- PixiLang
- Pascal
- Python 2
- Python 3
- Brainfuck
- x86 ASM
- Go
- R
Автор решения: 0xdb
→ Ссылка
SQL, PL/SQL Oracle
select 'Hallo, world!!!' output from dual
/
OUTPUT
---------------
Hallo, world!!!
exec dbms_output.put_line ('Hallo, world!!!')
Hallo, world!!!
Автор решения: MaxU
→ Ссылка
Brainfuck
-[------->+<]>-.-[->+++++<]>++.+++++++..+++.[->+++++<]>+.------------.---[->+++<]>.-[--->+<]>---.+++.------.--------.-[--->+<]>...
Автор решения: MaxU
→ Ссылка
x86 ASM
org 0x100 ; .com files always start 256 bytes into the segment
; int 21h is going to want...
mov dx, msg ; the address of or message in dx
mov ah, 9 ; ah=9 - "print string" sub-function
int 0x21 ; call dos services
mov ah, 0x4c ; "terminate program" sub-function
int 0x21 ; call dos services
msg db 'Hello, World!!!', 0x0d, 0x0a, '$' ; $-terminated message
Автор решения: MaxU
→ Ссылка
Go
package main
import "fmt"
func main() {
fmt.Println("Hello, World!!!")
}
Автор решения: 0xdb
→ Ссылка
AWK
$ awk --assign=var="Hello, World!" 'BEGIN { print var; }'
Hello, World!
Автор решения: Aziz Umarov
→ Ссылка
C#
using System;
namespace Sample
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Hello World!!!");
}
}
}
Автор решения: Victor VosMottor
→ Ссылка
Stuck 0 bytes
Я не шучу... Думаю только надо пустой код добавить или нет.