I am trying to go through a string to find dates in format of 19XX or 18XX, where XX can be any integers. Here is the basic set up:
var myLongString = "The Cold War (Russian: Холо́дная война́, Kholodnaya voĭna) was the continuing state from roughly 1946 to 1991 of political conflict...";
function getDates(myLongString) {
//use regular expressions to create a list of words in the "19XX" or "18XX" format
//and then return that list
}
Thanks for any help.
1 Answer