If we are to use our hobnob account on a day-to-day basis, it would be annoying to have to switch to the root account every time we want to install something. Luckily, in Linux permissions can be assigned to each user, as well as to a named group of users. Linux provides a sudo group, which allows users within that group to run commands requiring root privileges, simply by prepending the command with the sudo keyword and providing their password. Therefore, we should add our hobnob user account to the sudo group.
While still logged in as root, run the following command:
root@hobnob:# usermod -aG sudo hobnob
The -G option specifies the group we are adding the user to, and the -a flag appends the user to the group without removing them from other groups.
Now, try running sudo apt update from the hobnob account; it will prompt you for your password, and then it will execute the command as if you're the root user!