Download the latest ubuntu live desktop iso from the ubuntu official or any other linux server to your hard disk, if you have
ubuntu installed burn the iso with (startup disk creator) to the usb falsh drive and boot from your pc.
In windows or other linux distrubations use the any burn image to usb flash drive application or download the
etcher for windows or linux.
To start the usb flash drive, in your pc boot sequence select the boot from usb.
This will load the live ubuntu distribution from there you can install the ubuntu to your hard disk.
aptitude install update-manager-core
Then run the command:
do-release-upgrade
For kubuntu run the command:
do-release-upgrade -m desktop -f DistUpgradeViewKDE -d
for gui run:
kdesudo "do-release-upgrade -m desktop -f DistUpgradeViewKDE -d" &
or Press Alt-F2 and then run kubuntu-devel-release-upgrade.