Am I over the speed limit? Given an ascii-art road and the time it took me to cross it, tell me if I was speeding.

Units

Distance is in the arbitrary unit of d. Time is in the arbitrary unit of t.

The road

Here is a simple road:

10=====


The 10 means 10 d per t. That is the speed limit for the road. The road has 5 =s, so its d is 5. Therefore, if I cross that road in 0.5 t, I went 10 d per t, because 5/0.5 = 10. The speed limit of that road is 10, so I stayed within the speed limit.

But if I cross that road in 0.25 t, I went 20 d per t, because 5/0.25 = 20. The speed limit of that road is 10, so I went 10 over the speed limit.

Examples and calculations

Note that input 1 is the time I took to travel the road, and input 2 is the road itself.

Here is a complex road:

Input 1: 1.5
Input 2: 5=====10=====


The fastest I could have (legally) gone on the first road (the first 5 =s) is 5 d per t. Since 5 (distance) divided by 5 (speed limit) is 1, the fastest I could have gone on that road is 1 t. 

On the next road, the speed limit is 10 and the distance is also 5, the fastest I could cross that is 0.5 (5/10). Totaling the minimum times results in 1.5, meaning I went at exactly the speed limit.

Note: I know, I might have been going really fast on one road and really slow on another and still cross in 1.5, but assume the best here.

A final example:

Input 1: 3.2
Input 2: 3.0==========20===


The first road is 10 long and has a speed limit of 3, so the minimum time is 3.33333... (10 / 3.)

The second road is 3 long and has a speed limit of 20, so the minimum time is 0.15 (3 / 20.)

Totaling the times results in 3.483333333... I crossed it in 3.2, so I had to be speeding somewhere.

Notes:


You must output one distinct value if I am undoubtedly speeding, and another different value if I might not be.
Your program or function may require input or output to have a trailing newline, but please say so in your submission.
Your first input will be my speed. It will be a positive float or integer or string.
Your second input will be the road. It will always match the regex ^(([1-9]+[0-9]*|[0-9]+\.[0-9]+)=+)+\n?$. You may test out potential inputs here if you are interested.
You may take input in 2 parameters of a function or program, in 2 separate files, from STDIN twice, or from a space-separated string passed to STDIN, a function, a file or a command-line parameter.
If you would like to, you can change the order of the inputs.
Any questions? Ask below in comments and happy code-golfing!
Python 2, 71 bytes



m,s=input()
for c in s.split('=')[:-1]:s=float(c or s);m-=1/s
print m&lt;0


Try it online!

Python's dynamic type system can take quite some abuse.

Splitting the input string s.split('=') turns k equal signs into k-1 empty-string list elements (except at the end, where one must be cut off). For example,

"3.0===20====".split('=')[:-1] == ['3.0', '', '', '20', '', '', '']


The code iterates over these elements, updating the current speed s each time it sees a number. The update is done as s=float(c or s), where if c is a nonempty string, we get float(c), and otherwise c or s evaluates to s, where float(s) just keeps s. Note that c is a string and s is a number, but Python doesn't require doesn't require consistent input types, and float accepts either.

Note also that the variable s storing the speed is the same one as taking the input string. The string is evaluated when the loop begins, and changing it within the loop doesn't change what is iterated over. So, the same variable can be reused to save on an initialization. The first loop always has c as a number, so s=float(c or s) doesn't care about s's initial role as a string.

Each iteration subtracts the current speed from the allowance, which starts as the speed limit. At the end, the speed limit has been violated if this falls below 0.