Republican presidential nominee Donald Trump speaks during the presidential Ddbate at Hofstra University in Hempstead, New York. (Drew Angerer/Getty Images)

As Donald Trump and Hillary Clinton sparred over foreign policy during the debate, Trump was asked about his judgment when it came to the Iraq war — something he falsely said he never supported.

Moderator Lester Holt wanted to know: how was his judgment about the war different from that of Clinton, who voted in favor of invading Iraq while in the Senate in 2002?

"Well, I have much better judgment than she does. There's no question about that. I also have a much better temperament than she has, you know?" Trump said.

The Republican nominee said Clinton has spent "hundreds of millions of dollars" on advertising aimed at him.

"I think my strongest asset, maybe by far, is my temperament. I have a winning temperament. I know how to win," he said.

Here are the key moments from the first 2016 presidential debate between Hillary Clinton and Donald Trump on Sept. 26. NBC Nightly News anchor Lester Holt moderated the debate at Hofstra University in New York. (Sarah Parnass/The Washington Post)

Clinton rebutted by speaking about foreign policy, including the Iranian nuclear deal, and a comment Trump made earlier this month, stating he would blow Iranian ships out of the water if they made improper "gestures" toward American vessels.

"That is not the right temperament to be commander-in- chief, to be taunted," Clinton said.

Clinton then accused Trump of having a cavalier attitude toward nuclear weapons.

"So a man who can be provoked by a tweet should not have his fingers anywhere near the nuclear codes, as far as I think anyone with any sense about this should be concerned," Clinton said, using a line she has deployed in the past.

"That line's getting a little bit old, I must say," Trump shot back at Clinton.

"It's a good one, though," Clinton retorted.