using namespace std; int main() { int x=5.0,negsum; int countneg=0; if(x<0.0) { negsum=negsum+x; countneg=countneg+1; } ret | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
- 1

using namespace std; int main() { int x=5.0,negsum; int countneg=0; if(x<0.0) { negsum=negsum+x; countneg=countneg+1; } ret

this program has no output what z the mistake anyone can tell me.. frndzz

20th Nov 2016, 7:28 PM
aniket gupta
aniket gupta - avatar
4 Answers
+ 3
-You are missing #include<iostream> -You are declaring a int with a float decimal format -You are declaring a useless conditional -return 0 All that is wrong, but you are clearily trolling
20th Nov 2016, 7:37 PM
Aldo Alexandro Vargas Meza
Aldo Alexandro Vargas Meza - avatar
0
the lst one is return()
20th Nov 2016, 7:28 PM
aniket gupta
aniket gupta - avatar
0
how about posting your code in the message part, not the title? and it's has no output because you are not outputting anything.
20th Nov 2016, 7:39 PM
asdadasdsaczxc
0
I get it .. # thnkss I have done blunder mistakes yeahh...
1st Dec 2016, 12:11 PM
aniket gupta
aniket gupta - avatar