apt is the package manager of the Debian and Ubuntu distributions. It installs, updates and removes software from repositories, resolving dependencies. apt update refreshes the list of available packages, apt install installs, apt upgrade applies updates.
Example
sudo apt update && sudo apt install -y htop