sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak
sudo vim /etc/apt/sources.list

Remove sources.list content using below instead.

deb <> xenial main
deb-src <> xenial main
deb <> xenial-updates main
deb-src <> xenial-updates main
deb <> xenial universe
deb-src <> xenial universe
deb <> xenial-updates universe
deb-src <> xenial-updates universe
deb <> xenial-security main
deb-src <> xenial-security main
deb <> xenial-security universe
deb-src <> xenial-security universe
sudo apt-get update
sudo apt-get -f install
sudo apt-get -y upgrade

Use aptitude instead of apt-get

sudo apt-get install aptitude

aptitude issues

W: Unable to read /etc/apt/preferences.d/ - DirectoryExists (2: No such file or directory)

To fix

mkdir /etc/apt/preferences.d
E: The method driver /usr/lib/apt/methods/https could not be found.

To fix

sudo wget <>
sudo dpkg -i apt-transport-https_1.6.1_all.deb