I was using the old version of nodejs. Then i removed the old version using "rm rf- " command, but it was still showing the version when i run the "node -v " command, so i searched and deleted some more files. Now when i try to install:- it does not install and show the following message:-
sudo apt-get install npm
Reading package lists... Done
Building dependency tree
Reading state information... Done npm is already the newest version (3.5.2-0ubuntu4). 0 upgraded, 0 newly installed, 0 to remove and 70 not upgraded.