happy birthdaydear fred happy birthday to youhappy birthday to youhappy birthday to youhappy birthdaydear lucy happy birthday to youwell nowthat certainly seems to workand we've removed some of the duplication by defining the happy function howeversomething still doesn' feel quite right we have two functionssingfred and singlucythat are almost identical following this approachadding verse for elmer would have us create singelmer function that looks just like those for fred and lucy can' we do something about the proliferation of versesnotice that the only difference between singfred and singlucy is the name at the end of the third print statement the verses are exactly the same except for this one changing part we can collapse these two functions together by using parameter let' write generic function called sing def sing(person)happy(happy(print("happy birthdaydear"person "happy(this function makes use of parameter named person parameter is variable that is initialized when the function is called we can use the sing function to print verse for either fred or lucy we just need to supply the name as parameter when we invoke the function sing("fred"happy birthday to youhappy birthday to youhappy birthdaydear fred happy birthday to yousing("lucy"happy birthday to youhappy birthday to youhappy birthdaydear lucy happy birthday to youlet' finish with program that sings to all three of our birthday people def main()sing("fred"print(