I know that the latitude and longitude of Chicago is: 41.8819° N, 87.6278° W. Also the lat and long of united states is: 38.8833° N, 77.0167° W . How do I determine from latitude and longitude that chicago is in united states: is there some algorithm to do the same?
Also should not the latitude and longitude of a place be described by a lot of values rather than a single value -- e.g. united states is a big country, then how can we describe it by two points: 41.8819° N, 87.6278° W??
Can someone please help with this. Also I am coding in C/C++, it will be great if there is an library which will help me do the same using C/C++?