How to check the installed Ubuntu version?

There are many ways we can find the Ubuntu version from the Ubuntu operating system. The most commonly used command to find the Ubuntu version is the lsb_release. Following is the command:

$ lsb_release -a

#Output 
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 18.04 LTS
Release:    18.04
Codename:   bionic

If we just want to print the Ubuntu version then we can use the -d flag with lsb_release

$ lsb_release -d

#Output 
Description:    Ubuntu 18.04 LTS