Assuming uniform distribution in the range of MD5 and SHA-1 hashes for random strings (this is not the case), and suppose we are talking only about two strings and not talking about a string pool (therefore, we avoid birthday-paradoxical complexity):
The MD5 hash is 128 bits wide, and SHA-1 is 160. Given the above assumptions, two lines A and B have a collision probability P if both hashes collide. So,
P(both collide) = P(MD5 collides) * P(SHA-1 collides)
AND
P(MD5 collides) = 1/(2^128) P(SHA-1 collides) = 1/(2^160)
So,
P(both) = 2^-128 * 2^-160 = 2^-288 ~= 2.01 x 10^-87
Again, if you have a row pool and you are trying to determine the probability of collisions with the pool, you are in the domain of the birthday paradox , and this probability, which I calculated here, does not apply. This and the hashes are not as uniform as they should be. In fact, you will have a much higher level of collisions, but it will still be tiny.
EDIT
Since you are dealing with a paradoxical birthday situation, use the same logic as solving the paradoxical birthday. Let's look at this in terms of only one hash function:
N := the number of hashes in your pool (several hundred million) S := the size of your hash space (2^288) Therefore, P(There are no collisions) = (S!)/(S^N * (S - N)!)
Suppose we have a good even number of hashes, such as 2 ^ 29 (approximately 530 million).
P = (2^288!)/(2^288^(2^29) * (2^288 - 2^29)!)
In short, I donβt even want to think about calculating this number. I donβt even know how you can evaluate it. At the very least, you need an arbitrary precision calculator that can handle huge factorials without dying.
Note that the probabilities will follow a curve starting at almost 0 for N = 1 or 2 , and it will reach 1 when N >= 2^288 , in form similar to the one on the Wikipedia page for the paradox of the day.
The birthday paradox reaches P = .5 when N = 23 . In other words, the chance of collision is 50% when N is 6% of S. If it scales (I'm not sure it is), it means that the probability of collision will be 50% if you have 6% of 2 ^ 288 hashes. 6% of 2 ^ 288 is around 2,284. Your N value (several hundred million) is nowhere near. This is practically negligible compared to your S, so I donβt think you have anything to worry about. Collisions are not very likely.