On ubuntu, first try running the visual studio code from the terminal with:
code
If there is any package error, install it. Then, if there is a black screen, go to:
sudo vi /usr/share/applications/code.desktop
Add disable gpu line as follows:
Exec=/usr/share/code/code --disable-gpu %U
source share