how to install packages in debian based distributions

when installing packages in ubuntu you have three package managers to choose from: apt, apt-get and aptitude. each package manager is used in the same way for example: sudo aptitude install firefox. where possible you should use aptitude as it is better at handling any problems you run into, in most distributions you need to install it. apt is the official package manager. apt-get is a deprecated package manager, in most cases you can (and should) pass the exact same commands to apt for the same or similar results.