If the king is the last piece left on the board, how many moves does the opponent have to Checkmate?
if there is only the king left on the board then your opponent has fifty moves time to checkmate you.
This is called the Fifty Move Rule.
You can claim a draw if no capture has been made and no pawn has been moved in the last fifty moves.
A move consists of two half-moves.
A move is completed when your opponent has completed his half-move followed by you completing your half-move.
This rule stops a player with no chance of winning to play on indefinitely or seeking to win by making you tired.
All basic checkmates can be done easily under 50 moves.