Defense Secretary Robert Gates said Wednesday that from what he has seen, both John McCainJohn McCainFortune's 'Greatest Leaders' list includes Samantha Bee, snubs Trump McCain: Nunes's actions 'very disturbing' McCain calls North Korean leader a 'crazy, fat kid' MORE and Barack ObamaBarack ObamaSchiff: Nunes ‘blindsided’ me on Trump intel As Persian New Year passes, Iranian resistance sees reasons for hope NRCC claims Obama surveillance of Trump 'confirmed' MORE would take a "sensible approach" to Iraq once in office.

"Based on what I read in the newspapers, I think either person who is elected president is going to come in and take a close look at it," Gates said during an interview with CNN.

Despite the wide distance between Obama and McCain on Iraq, Gates said both will heavily weigh the options when approaching the "endgame" in Iraq.

"I've said repeatedly we can't get the endgame wrong. The next president would suffer the greatest consequences if we do get the endgame wrong, so I think whoever's elected is likely to take a fairly sensible approach to it," Gates said.