Meaning/Usage: To decide to do something as the situation develops; choosing to deal with a situation as more events unfold.
Explanation: The original meaning is to play music without using a score or music sheet to look at. Just as a musician will play something unplanned without looking at something, this idiom is to do something unplanned depending on the situation.