0

Help me :c

good, I have a problem, how can I print the parameters of a function together, next to each other, example if i have the following: def Sum (a,b)        print ("The answer is" ab) Sum (7,8) How do I get the terminal to return this to me? The answer is 78 thanks in advance, i'm new :c

15th May 2020, 8:52 PM
Aaron Kaleb Arteaga Rodriguez
Aaron Kaleb Arteaga Rodriguez - avatar
4 ответов
+ 4
You can use a format string: print (f"The answer is {a}{b}")
15th May 2020, 8:54 PM
HonFu
HonFu - avatar
+ 1
Oh thanks, that great community
15th May 2020, 9:10 PM
Aaron Kaleb Arteaga Rodriguez
Aaron Kaleb Arteaga Rodriguez - avatar