For many years I acted as a magistrate, sitting in court sometimes three days a week. My son is a lawyer and he now spends a fair amount of time in court also. The one thing we both know about court is that you cannot prepare for what might happen on any given day.
The bottom line is being quick of thought but also before asking any questions try your very best to be aware of the possible answers that might come your way. I have to say i have often left the court and on the way home chuckled to myself about some of the things that people have without thinking said.
There is a story of an event that happened in a small court in the USA.