0

Hey

Hey i have now this question for all you Lambdas The given code takes a number as input and uses a lambda function to calculate its double and output the result. Change the code to calculate the cube of the input and output it. Sample Input 3 Sample Output 27 The cube of a number is its third power. i hope someone answer and explaint how he fix it

8th Oct 2021, 8:50 PM
Raoof Zakarna
5 ответов
+ 4
To calculate the cube of x you have to use: x**3 https://code.sololearn.com/cq8KTuYiAb3n/?ref=app
8th Oct 2021, 9:53 PM
Simon Sauter
Simon Sauter - avatar
8th Oct 2021, 8:55 PM
Simon Sauter
Simon Sauter - avatar
+ 1
yes im sorry but im new here i will read the rules now this is my attempt : x = int(input()) y = (lambda z:z*4)(x) print(y)
8th Oct 2021, 8:58 PM
Raoof Zakarna
0
Paython
8th Oct 2021, 9:03 PM
Raoof Zakarna
0
thank you simon 👌
8th Oct 2021, 9:57 PM
Raoof Zakarna