I need to programmatically verify that only Windows 10 is installed on a computer.
This information is manually available in Windows 10 by navigating to Advanced System Settings >> Advanced Tab >> Settings in Startup and Recovery Section >> Opening the drop down menu "Default operating system
Perhaps there is a way using the BCDedit command line tool.
I don't know much concerning having multiple operating systems, but if you want a PowerShell answer to view the current windows OS...
^ This will return some general info about the OS
^ This will select all the properties available from the Win32_OperatingSystem class that has a fair amount of information to look through
^ This will get the name of the specific OS installed