Swift/Declaration/var: Difference between revisions

imported>Fire
Created page with "変数を定義するときに使用する。変更しない場合は、varよりもこちらを推奨。 == Simple な構文 == <syntaxhighlight lang="Swift"> let valiable name: type = expression </syntaxhighlight> == Getter, Setter == get に式を入れて、return で返すとかできる。setは、設定したときに呼び出される。設定した値は ''newValue'' で読み出せる。 [https://qiita.com/miyakooti/items/a8ac0896eb912c60bd1f 参考] <synta..."
 
(No difference)