多種語言實現打印hello word

mysql版:

delimiter $$
create function sayhello() returns varchar(20)
begin
return 'hello word';
end $$
delimiter ;

結果:
在這裏插入圖片描述
python版:

def sayhello():
    print('hello word')

結果:
在這裏插入圖片描述
C版:

# include <stdio.h> 
void SayHello() {
    printf("hello word");
}

結果:
在這裏插入圖片描述
C++版:

# include <iostream>
using namespace std;
void SayHello() {
 cout << 'hello word' << endl;
}

結果:
在這裏插入圖片描述

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章