
9/30(月)プログラミング勉強
時間:30分
用途:Progate[JavaScript]
内容
変数の更新
のちに代入したい値は letをつけない
letname="John";
console.log(name);
name="kate"
console.log(name);既に定義した変数numberに3を足したい
let number=2;
console.log(number);省略した書き方
x=x+10 →x+=10定数について 値を更新できない
const name="John"テンプレートリテラル
+の記号のような使い方をする
${が定数
console.log(`こんにちは、${name}さん`);
いいなと思ったら応援しよう!
