Skip to content

Latest commit

 

History

History

powers-of-i

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

i is the imaginary unit, it is defined by i² = -1, therefore it is a solution to x²+1=0.

Task

is to write a function pofi that returns i to the power of a given non-negative integer in its simplest form as a string (answer may contain i).