An algorithm is a set of directions for carrying out a task. Sounds about right
The
alignment sheet
The alignment sheet in the format cells dialog
box is used to position data in a cell by left or right aligning, centering,
aligning at the top or bottom and rotating as well. For instance, if you choose
to enter 90 in the degree area, the text will read vertically from bottom to
top in the cell.
Answer:
Nothing is wrong, the code works as intended.
Explanation:
There is nothing wrong with the code.It will work fine.
Working of the code:-
An integer variable named base is declared and initialized with the value 2.Then the exponent variable is taken as input.Then the answer of the base raised to the exponent is stored in the variable answer using the pow method of the Math package.Then checking with the if statement if the answer is less than or equal to 256 means that the exponent is less than 8 hence printing exponent is 8 or less.