.NET 7.0 SDK is installed but not recognized on Ubuntu 22.04

Removed all .NET packages

sudo apt remove 'dotnet*'
sudo apt remove 'aspnetcore*'

Deleted PMC repository from APT, by deleting the repo .list file

sudo rm /etc/apt/sources.list.d/microsoft-prod.list

Install .NET 7 SDK

sudo apt update
apt-get install -y dotnet-sdk-7.0

References
https://stackoverflow.com/questions/73312785/dotnet-sdk-is-installed-but-not-recognized-linux-ubuntu-popos-22-04