import random


def make_random_tree(size):
  """Make a random binary tree with size nodes."""
  if size <= 1:
    return 0
  r = random.randint(1, size-1)
  return (make_random_tree(r), make_random_tree(size-r))