#include
using namespace std;
int main() {
unsigned int n;
unsigned int sum=0;
signed int result = 0;
while(result<0)
{
cin>>n;
result=sum+n;
cout<<n<<endl;
}
return 0;
}
#include
using namespace std;
int main() {
unsigned int n;
unsigned int sum=0;
signed int result = 0;
while(result<0)
{
cin>>n;
result=sum+n;
cout<<n<<endl;
}
return 0;
}
hello @suryansh771
check this condition of ur will loop.
it is always false and that is why u r not getting any output
i am not able to correct the code pls help me with correct code
check this->

what does #include<bits /stdc++.h> mean here
are we not using #include
and using namespace std
u use iostream only.
i have just started doing coding i dont know much about header files i am fimiair only with iostream
nither in the video of fundamental progreamming did the tutor teached us about it
that is why i dont want to confuse u.
the issue is with ur ide only.
use iostream in place of bits/stdc++.h
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.