I checked multiple articles to get SharePoint Central Administration URL using PowerShell then open the SharePoint Central Administration URL from PowerShell but most of these posts get SharePoint Central Administration URL from the registry entry as below
Get-ItemProperty -Path 'HKLM:HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\16.0\WSS\' -Name CentralAdministrationURL | select CentralAdministrationURL
I am wondering if there is a better way to get SharePoint Central Administration URL from PowerShell without using Registry entry for SharePoint 2016.