function foo() {
var secondDigit = 1
let firstDigit = secondDigit
firstDigit++
return firstDigit
}
foo()
console.log(typeof firstDigit)
console.log(typeof secondDigit)Ответ:
undefined
undefined
JavaScript test | #JavaScript
JA JavaScript test @js_test · 9.68K subscribers function foo() {
var secondDigit = 1
let firstDigit = secondDigit
firstDigit++
return firstDigit
}
foo()
console.log(typeof firstDigit)
console.log(typeof secondDigit)