LoginSignup
1
0

More than 3 years have passed since last update.

Ruby基礎知識

Posted at

2019/7/10

Ruby学習

puts "Hello World"

出力結果がコンソールに表示される

数値の出力と足し算/引き算

puts 数字の出力
puts 1 + 1 足し算
puts 1 - 1 引き算
puts 1 * 1 掛け算
puts 1 / 1 割り算
puts 9 % 2 余り算
puts "1 + 1" 文字列として表示される

変数とは

※イメージ
→変数=値を入れておく箱
スクリーンショット 2019-07-10 9.00.47.png

変数の定義

※重要※

プログラミングの「=」は「左の変数に右の値を入れる」という意味で、これを代入

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0