Write a python program to execute Exponentiation of a number.

Thiru Malai
2 min readJun 9, 2021

What is exponentiation?

Exponentiation is a mathematical operation where a value is multiplied number of times with itself.

CONCEPTS INVOLVED:

FUNCTION

A function is a block of code. The statement inside the function will be executed only if it is called.

The date passed inside the function is called Parameters. A function can return those data as a result.

Creating and calling the Function:

Example:

Output:

Information can be passed into functions as arguments. Arguments are specified after the function name, inside the parentheses. You can add as many arguments as you want, just separate them with a comma.

If Statement:

If statement will be executed only if the condition is true if the condition is false no output will be shown.

if (condition):
statement
statement
...

In this program we have 2 arguments base and exp.

Code:

Output:

Refer GUVI:

--

--