I have data in an Excel spreadsheet that has 10,000 rows with the following structure:
Country | Region | City | Latitude | Longitude
-----------------------------------------------------
USA | CA | Los Angeles | 34°03′N | 118°15′W
...
The first three columns effectively constitute a primary key. I would like to load this data into a C# program so that I can have expressions conceptually like the following:
string lat = someDataStructure["USA"]["CA"]["Los Angeles"].latitude;
I would also like to be able to do things like get a list of all latitudes of cities in California.
What would be the best way to load this data from Excel? Would I use Linq for this?
(I cannot use third-party libraries/modules for this task.)