formulahendry / formulahendry/vscode-code-runner
Spaced arrays in terminal and nodejs
- Dominant language
- TypeScript
- Stars
- 2.4k
- Forks
- 351
- PR merge metrics
- No merged PRs in 30d
Description
Type: Bug
I don't exactly what is happening, but the output while i use the code runner is showing spaced arrays when i apply methods like .pop(), .shift(), .push() and similar.
The code itself:
let arr = [1,3,5,7,9]
let teste = arr.push(14,13,false,[])
let ultimoitem = arr.pop()
console.log(ultimoitem)
console.log(arr)
let primeiroItem = arr.shift()
console.log(primeiroItem)
console.log(arr)
teste = arr.unshift(4,5,6)
console.log(teste)
let arr2 = arr.slice(2,5)
console.log(arr2)
console.log(arr)
let arr3 = arr.splice(2,5)
console.log(arr)
console.log(arr3)
The output:
[]
[
1, 3, 5,
7, 9, 14,
13, false
]
1
[
3, 5, 7,
9, 14, 13,
false
]
10
[ 6, 3, 5 ]
[
4, 5, 6,
3, 5, 7,
9, 14, 13,
false
]
[ 4, 5, 14, 13, false ]
[ 6, 3, 5, 7, 9 ]
Note: I'm using the plug in "Code runner ".
Extension version: 0.12.2
VS Code version: Code 1.93.1 (38c31bc77e0dd6ae88a4e9cc93428cc27a56ba40, 2024-09-11T17:20:05.685Z)
OS version: Windows_NT x64 10.0.19045
Modes:
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.