C语言(C语言编译工具,如codeBlocks)
#include<stdio.h>
int main(){
<strong>printf("hello world");</strong>
}
java(java编译工具:eclipse)
public class helloWorld {
public static void main(String args[]){
<strong>System.out.print("hello world");</strong>
}
}
perl(可用perl编译工具,如Strawberry Perl)
print"hello world";
编译过程:
Windows下怎么运行Perl程序显示输出"hello,world"语句
python
print("hello world")
php
echo"hello world";
C++
#include <iostream>
using namespace std;
int main() {
<h4> cout << "hello world" << endl; </h4> return 0;
}
javaScript
document.write("hello world");
alert("hello world");
JS控制台:console.log("hello world");
另外。。。
ruby
print("hello world")
p"hello world"
puts %Q.hello world
参考:
ruby 16种 hello world 写法
最后
以上就是自觉服饰最近收集整理的关于各种语言输出hello world,如C/java/perl/python/php/C++的全部内容,更多相关各种语言输出hello内容请搜索靠谱客的其他文章。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复