Juan sold half of his comic books and then bought six more. If he now has 36 comic books, with how many did he begin?