The king is left alone on the chessboard. In spite of this loneliness, he doesn't lose heart, because he has business of national importance. For example, he has to pay an official visit to square *t*. As the king is not in habit of wasting his time, he wants to get from his current position *s* to square *t* in the least number of moves. Help him to do this.

In one move the king can get to the square that has a common side or a common vertex with the square the king is currently in (generally there are 8 different squares he can move to).
The first line contains the chessboard coordinates of square *s*, the second line — of square *t*.

Chessboard coordinates consist of two characters, the first one is a lowercase Latin letter (from a to h), the second one is a digit from 1 to 8.
def shortest_path(start, goal):
  """Finds the shortest path from the starting node to the goal node.

  Args:
    start: The starting node.
    goal: The goal node.

  Returns:
    A list of moves, or None if there is no path from the starting node to the goal node or if the start or goal position is invalid.
  """

  if not is_valid_position(start) or not is_valid_position(goal):
    return None

  queue = [start]
  visited = set()

  while queue:
    node = queue.pop(0)
    visited.add(node)

    if node == goal:
      return get_path(node)

    for neighbor in get_neighbors(node):
      if neighbor not in visited:
        queue.append(neighbor)

  return None

def get_path(node):
  """Gets the path from the starting node to the given node.

  Args:
    node: The node to get the path to.

  Returns:
    A list of moves, or None if there is no path to the given node.
  """

  path = []
  while node != None:
    path.append(node.move)
    node = node.parent

  path.reverse()
  return path

def get_neighbors(node):
  """Gets the neighbors of the given node.

  Args:
    node: The node to get the neighbors of.

  Returns:
    A list of nodes.
  """

  neighbors = []
  for move in ["L", "R", "U", "D", "LU", "LD", "RU", "RD"]:
    neighbor = node.get_neighbor(move)
    if neighbor is not None and is_valid_position(neighbor):
      neighbors.append(neighbor)
  return neighbors

def is_valid_position(position):
  """Returns True if the given position is a valid position on the chessboard, False otherwise."""

  return 0 <= position[0] <= 7 and 0 <= position[1] <= 7

def main():
  start = input()
  goal = input()

  shortest_path = shortest_path(start, goal)
  if shortest_path is None:
    print("No path found")
  else:
    print(len(shortest_path))
    for move in shortest_path:
      print(move)

if __name__ == "__main__":
  main()
