ああ、ちなみにpermutationやcombinationのアルゴリズムは簡単w