#K51467. Flower Arrangements
Flower Arrangements
Flower Arrangements
You are given two integers M and K, where M represents the number of different flower types and K represents the number of positions in a row. Your task is to determine the total number of possible arrangements when placing K flowers in a row. Each position can be occupied by any of the M types, and arrangements with repeated types are allowed.
The answer is given by the expression \(M^K\), where \(M\) is raised to the power of \(K\). For example, if M = 3 and K = 2, there are \(3^2 = 9\) possible arrangements.
inputFormat
The input is provided via stdin and consists of two space-separated integers:
M
: the number of different types of flowers.K
: the number of flowers to arrange in a row.
Constraints: \(1 \leq M, K \leq 10^x\) (subject to problem limits).
outputFormat
Output a single integer to stdout representing the total number of possible arrangements of the K flowers in a row.
## sample3 2
9