Mohan's Physics Problem

View as PDF

Submit solution

Points: 7
Time limit: 1.0s
Memory limit: 16M

Author:
Problem types
Vincent Massey SS - 2014 Senior Contest #1

Despite Mohan's tests being hard enough, you realized after you started that you forgot your calculator! You work out the answer to the quantum physics question to be n^k. Although you don't have a calculator, you have your laptop at your disposal. You decide to write a program to solve the answer for you.

Given n and k, find the value of n^k expressed in scientific notation.

Input Specification

Two space-separated integers, n and k (2 \le n \le 100; 1 \le k \le 500\,000).

Output Specification

Print the value of n^k using scientific notation. Print the significand on the first line and the exponent on the next. The significand must be rounded and displayed to 3 significant digits.

Sample Input

2 8

Sample Output

2.56
2

Comments