Answer:
sample output
Enter f0 = 440
440.0,466.1637615180899, 493.8833012561241,
523.2511306011974, 554.3652619537443
Step-by-step explanation:
 import math // math library 
 def RaiseToPower(): // RaiseToPower method
 r = math.pow(2,1/12) //r = 2^(1/12)
f0 = float(input('Enter f0 : ')) //input from user
 
 //a key has a frequency,sy f0
 
 print(f0,end=' ') //Display statement
 for n in range(1,5): //Iterate the loop up to the next 4 higher key Hz 
 n = f0 * math.pow(r,n) //calculate the fn value
 print(fn,end=' ') //Display statement
 RaiseToPower() //Call RaiseToPower method