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 5 years have passed since last update.

勉強 独り言 

0
Posted at

rubyとrailsについて独り言を書く、
間違っている点もあるかと思います。

rubyは配列
def
end
で区切り
本文は 変数=ハッシュ から始まる。
例、cars = []
case input
when "0"
register_data(cars)
when "1"
show_cars(cars)
when "2"
exit
else
puts "無効な値です"
end
end
のようにcaseを使い、もしーの場合を使うことができる。
when2を選択したなら、exitなので終了する。
2を押さない限り終了しない。

railsはバグ、エラー問題を中心に解いた。
エラー時の濃い赤い線にはshowなどエラーの場所を教えてくれている。
薄い赤い線にも場所が書いてあったりする。
上から英文を読むとだいたいの場所がわかる場合もあるが。
MVC、7つのアクションを理解していないと解けない問題が多い。

投稿フォームはshowのform withと関係があり
ホームページの見た目はshow。
中のシステムのどこと関係があるのか理解して
コードを書く。
関係性が分からないと解けない。
見た目はshow
では、中身は??後日改めて記載する。

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?