Ruby メソッド 作成
【例】
#nicemethod メソッド
def nicemethod
print "very nice! method\n"
end
#nicemethodメソッドを実行
nicemethod()
以上、Ruby メソッド 作成でした
#nicemethod メソッド
def nicemethod
print "very nice! method\n"
end
#nicemethodメソッドを実行
nicemethod()
以上、Ruby メソッド 作成でした
前の記事:Ruby times 繰返し⇒
次の記事:Ruby ファイル読込⇒