input: Write a python function to check if there is a winner in a tic-tac-toe game.
  assert check_winner(['X', 'X', 'X', '_', '_', '_', '_', '_', '_']) == 'X'
  assert check_winner(['_', '_', '_', 'O', 'O', 'O', '_', '_', '_']) == 'O'
  assert check_winner(['_', '_', '_', '_', '_', '_', 'X', 'X', 'X']) == 'X'
  assert check_winner(['X', '_', '_', 'X', '_', '_', 'X', '_', '_']) == 'X'
  assert check_winner(['O', '_', '_', 'O', '_', '_', 'O', '_', '_']) == 'O'
  assert check_winner(['X', 'O', 'X', 'O', 'X', 'O', 'O', 'X', 'O']) == 'Draw'
output: def check_winner(board):
      # Check rows
      for i in range(0, 9, 3):
          if board[i] == board[i + 1] == board[i + 2] and board[i] != '_':
              return board[i]
      
      # Check columns
      for i in range(3):
          if board[i] == board[i + 3] == board[i + 6] and board[i] != '_':
              return board[i]
  
      # Check diagonals
      if board[0] == board[4] == board[8] and board[0] != '_':
          return board[0]
      if board[2] == board[4] == board[6] and board[2] != '_':
          return board[2]
  
      # Check if there is any empty space left
      if '_' in board:
          return 'Pending'
      
      return 'Draw'