Discussioni Q&A
Def Quiz
1 Voto
6 Rispostedefault arguement ?
0 Voti
2 Risposte#include <iostream>
using namespace std;
int sum(int a, int b=42) {
int result = a + b;
return (result);
}
int main() {
int x = 24;
int y = 36;
//calling the function with both parameters
int result = sum(x, y);
cout << result << endl;
//calling the function without b
result = sum(x);
cout << result << endl;
return 0;
}
why is da last function cout 66 and not 48 isn't it suppose to add 24+24?
1 Voto
6 RispostePython function
1 Voto
2 Rispostewhat is arguments?
1 Voto
2 RisposteWhere did I go wrong?
1 Voto
16 Rispostemap function
1 Voto
4 RispostePython functions
1 Voto
7 RisposteFunctions
0 Voti
3 RisposteExplain this code.
0 Voti
4 RispostePopolare oggi
??
1 Votes
Ошибка в приложении Sololearn
1 Votes
NEO V2.0
1 Votes
Hello guys,
1 Votes
Help me
1 Votes
how do they use javascript
0 Votes