0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

if文について

0
Last updated at Posted at 2023-03-17

if 関数について

- 初めに基本的な文法について

if 条件 then
  処理
end
例文)
if 点数が80点より高い

puts "良くできました"

end

※ 処理はifとendで囲む。

if文のコード

例文)
score = 94

if score > 80

puts "良くできました"

end

表示メッセージ

良くできました

※ 条件が成り立たないときは表示されない。

0
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
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?