arduino vscode upload choosing sketch

C
Down at the bottom, on the right
you'll see the Arduino status bar. There you'll find your board,
your programmer, your port... and the .ino file that you're compiling.
Click there, change the name to the sketch you want to compile and done!
Source

Also in C: