Cursos
Iniciar sesiónComenzar a aprender IA
Cursos
Iniciar sesiónComenzar a aprender IA

Sesiones de PyR

What happens if I assign a variable x to 8, and Y to x, can i later change what value x holds? Or is Y forced to be equal to 8?
rubyvariables
2 Votos
4 Respuestas
2nd Jun 2017, 9:40 AM
william
static int Pow(int x, int y = 2) { int result = 1; for (int i = 0; i < y; i++) /* this is the for loop that I don't understand.
c#methods
1 Voto
4 Respuestas
22nd Jan 2017, 5:13 PM
Steven Bennett
Steven Bennett - avatar
def add(x, y): return x + y def do_twice(func, x, y): return func(func(x, y), func(x, y)) a = 5 b = 10 print(do_twice(add, a, b)) anybody can explain what is the relevance of func in this code?
functionspython
1 Voto
4 Respuestas
21st Aug 2016, 4:57 AM
anju
How does return function work in python?
+defadd(x,do_twice(func,returnreturnxx,y):y):ydef
1 Voto
2 Respuestas
25th Aug 2020, 10:05 AM
Shakibur Rahaman
Shakibur Rahaman - avatar
def add(x, y): return x + y def do_twice(func, x, y): return func(func(x, y), func(x, y)) a = 5 b = 10 print(do_twice(add, a, b)) Please explain step by step Which is caller here? Explain the 3rd and 4th line ? why in 4th line we write add(add(x,y),add(x,y)) which is function of 1st line ? how can we write function after return statement insted of (x+y+x+y )=30?
python
0 Votos
2 Respuestas
29th Jul 2016, 7:22 PM
Rupam Das
Rupam Das - avatar
< Anterior12Siguiente >
En tendencia hoy
Best language?
0 Votes
Need suggestions
0 Votes
Bro can you fix yt error?
0 Votes
Need suggestions to learn AI and ML
1 Votes
Java full stack
0 Votes
Best code for creating games?
0 Votes
Calculator
0 Votes
Duration of heart refilling
0 Votes
progaming
0 Votes
Why isn't a linked video not working
0 Votes