I made a major mistake by putting in this code:
vim /etc/lightdm/lightdm.conf
and then changing the line
greeter-session=unity-greeter
to
greeter-session=lightdm-gtk-greeter
But now I get a low graphics error. I found some answers on how to fix this, but I am struggling with opening the terminal to do it. The instructions on this website How to change the LightDM theme/greeter? would be helpful if I could get into the terminal, but when I press Ctrl+Alt+F1 nothing happens except the cursor freezes.
So I am looking for a workaround and I considered changing grub as the terminal does open up there. But I ran into a new problem - grub does not recognize sudo
and other commands.