How to find Sharepoint version

Normally to find the Sharepoint version we approach Central administration page Central Administration > Operations > Servers in Farm

One more method using SQL query

SELECT Version FROM Versions WHERE VersionId = ‘00000000-0000-0000-0000-000000000000’

Also you can find Sharepoint version programmatically using API

using (SPSite site = new SPSite(“<Central Administration Site URL…..>”))
{
SPFarm farm = site.WebApplication.Farm;
Console.WriteLine(SPWebService.ContentService.Farm.BuildVersion.ToString());
}
Console.WriteLine(“Press any key to continue…..”);
Console.ReadLine();