Q&A Discussions
About default arguments
5 Votes
4 Answersdefault arguement ?
0 Votes
2 AnswersPython: return functions
2 Votes
3 Answers#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 Vote
6 AnswersPython function
1 Vote
2 Answerswhat is arguments?
1 Vote
2 Answerscommand line aregumente
0 Votes
3 AnswersWhere did I go wrong?
1 Vote
16 Answersmap function
1 Vote
4 AnswersParseInt(readline(),18)
0 Votes
3 AnswersPython functions
1 Vote
7 AnswersExplain this code.
0 Votes
4 AnswersHot today
Why this code still works
1 Votes
Python
1 Votes
I need help with my code please
0 Votes
Python related
1 Votes
Why won't canvas work?
2 Votes
++ Confusion in java
0 Votes
Pancakes, error or am I stupid?
1 Votes