Look at your bit of code there.
Imagine that "dist9" has the value 9.
So, is "dist9" less than 50?
Yes, so call "FrontLeft". This takes maybe a hundred microseconds.
Now, is "dist9" less than 20?
Yes, so call "backRight".
Test your smallest distance first and use an "else"