You can install vscode using following commands:
1- Start by updating the packages index and installing the dependencies by typing:
sudo apt update
2- sudo apt install software-properties-common apt-transport-https curl
3- Import the Microsoft GPG key using the following curl command:
curl -sSL https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add –
4- Add the Visual Studio Code repository to your system:
sudo add-apt-repository «deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main»
5- Install the Visual Studio Code package with:
sudo apt update
sudo apt install code