//Update your packages:
sudo apt-get update
//Install Curl to get the composer library:
sudo apt-get install curl
//Installing composer:
sudo curl -s https://getcomposer.org/installer | php
//Move the composer file to bin path :
sudo mv composer.phar /usr/local/bin/composer
//Verify composer installation :
composer