If you have installed the Code Runner extension, enable Run In Terminal option in Extensions settings.
Code Runner
Run In Terminal