How to call a standard console command from a custom one?

As the title said, I’m wondering is there anyway to inject Magento commands inside my custom commands?

For example, I want to create a custom command "hello:world"
This command is supposed to execute 2 commands “setup:upgrade” and “setup:di:compile” and few minor tasks.

Is it possible to do?

You can add your custom console command using the instruction: How to add custom console commands and handle them?
You can call the standard console commands as PHP methods.

I read that topic already, could you give me more specified related to this topic?
For “setup:upgrade” and “setup:di:compile

See the list of the Magento 2 embedded console commands
Each command in the list contains a link to an exact Magento 2 source code line.

So it is as simple as intial it in the constructor and run execute() function?