ZOJ Problem Set - 3553
A N-dimension hypercube. m kinds of color.
The input consists of several cases. Each case consists of two positive integers N and m (2 ≤ n ≤ 6, m ≤ 100000).
For each case, output the total number of different schemes mod 97654321.
Author: WU, Yingxin
Contest: ZOJ Monthly, October 2011