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 1 year has passed since last update.

🔰超初心者のこの先の超初心者の皆様に向けて#3

Posted at

*データ型と型推論
・型とは?(代表的な一部です)
Int型(整数)とは整数値を入れる型のこと
例: var myAge: Int = 30
Double型(小数点)とは小数点の数値を入れる型のこと
例: var height: Double = 185.5
String型(文字列)とは文字列を表す型のこと
例: let myName: string = "ayumu"

上記みたいに数値や文字によって使用される型がある。
ayumuは自分の名前ですが"ayumu"は数値ではないのでString型を使用して表すルールがあると覚えています。

*型推論とは?
例:let myName: String = "ayumu"が正式な型ですが
  let maName = "ayumu"にしてもコンパイル時にString型
  と推測してくれる。

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?