Is there any way to make desk-checking through the logic of a large program easier?

Large programs can have thousands of lines of code and checking the logic for every conditional statement, including nested conditionals, seems like a task that takes a ton of focus, are there any tips for it or does it just have to be done with patience and a ton of focus?