Reading a timeline
05AB1E, 19 18 bytes
Code:
ð¢>UágF²N>.bkX-¹+,
Explanation:
ð¢ # Count the number of spaces before the year starts
> # Increment by 1
U # Pop and store this into X
á # Keep the alphabetic characters of the second input
g # Take the length
F # For N in range(0, length), do...
² # Take the second input
N> # Push N and increment by 1
.b # Converts 1 to A, 2 to B, etc.
k # Find the index of that letter in the second input
X # Push X
- # index - X
¹ # Get the first input, which contains the year
+ # Add to the difference of the index
, # Pop and output the sum
Try it online!
Uses CP-1252 encoding.