Yes, Might be duplicate of following links Tried both links solutions but didn't worked for me.
Following is my /etc/hosts output:
127.0.0.1 kaushal
120.0.0.1 localhost.localdomain localhost
127.0.0.1 localhost.com
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
Following is my /etc/hostname output:
127.0.0.1 kaushal
120.0.0.1 localhost.localdomain localhost
127.0.0.1 localhost.com
Every time when I write command sudo apt-get update I get following error message.
sudo: unable to resolve host 127.0.0.1kaushal
Also in my terminal I get kaushal@127:~$ as following screenshot.

It was not like that before.
All this started happening after I change my username from
All Setting > Details > Device name
Any suggestion what's wrong with my machine?? How can I resolve this problem. Let me know if you want more details.