Q&A Discussions
problem with asterisk
1 Vote
1 Answercan someone please explain why this code keeps telling me complication error instead of outputting the value of speed.
#include <iostream>
using namespace std;
class myClass {
public:
void setcarspeed (int a){
speed=a;
}
int getcarspeed(){
return speed;
}
private:
int speed;
};
int main() {
myClass obj;
obj.setcarspeed (40);
cout<<obj.getcarspeed ;
return 0;
}
2 Votes
3 AnswersWhy not normal I/O
0 Votes
1 AnswerSolo Learns Code Playground
2 Votes
2 AnswersBackground-image Quality?
0 Votes
2 AnswersTime Limit exceeded
0 Votes
2 AnswersConnecting html with php
0 Votes
2 Answerswhat will be output??
#include <iostream>
using namespace std;
int main(int a)
{
cout << a << "\n";
return 0;
}
int main(char *a)
{
cout << a << endl;
return 0;
}
int main(int a, int b)
{
cout << a << " " << b;
return 0;
}
int main()
{
main(3);
main("Subodh");
main(9, 6);
return 0;
}
if output is compilation compilation error then how can we overload "main" function in C++
0 Votes
5 AnswersCode problems D: Help?
0 Votes
2 AnswersTransparent Problems
0 Votes
1 Answererro no sistema de login
0 Votes
2 Answers[BUG] C# opens as web :(
1 Vote
1 Answerfind the misstake plz......
0 Votes
1 AnswerWhy is there error?
0 Votes
2 AnswersIndetationError
0 Votes
1 AnswerNot Getting Proper Output
0 Votes
1 AnswerHot today
Why this code still works
0 Votes
Python
1 Votes
I need help with my code please
0 Votes
Python related
1 Votes
Why won't canvas work?
2 Votes
Ai courses
1 Votes