In my solution I have written
#include<stdio.h>
int main()
{
int num;
while(scanf("%d",&num)==1)
{
printf("%d",num);
}
return 0;
}
I don’t know where I am going wrong .
In my solution I have written
#include<stdio.h>
int main()
{
int num;
while(scanf("%d",&num)==1)
{
printf("%d",num);
}
return 0;
}
I don’t know where I am going wrong .
Can you add link to the problem…
Stop trolling. This problem does’nt exist.
Rewrite this statement-> printf("%d",num); as printf("%d\n",num); and you get AC
he is right the time limit is 1 sec which exceeded
can u provide the link to the question you are asking about?
Don’t know why it shows runtime error(NZEC) always.
here is my code in python:
while 1:
x=int(raw_input())
print x
Why am I getting wrong answer for the following code, can anyone help me with it please?
/* A program to take inputs*/
#include
#include
using namespace std;
int main()
{
int n;
register int c;
while(c!=EOF)
{
n=0;
c=getchar_unlocked();
for(;c>47&&c<58; c=getchar_unlocked())
{
if(c==47)
z=1;
n=(n<<1)+(n<<3)+c-48;
}
printf("%d\n",n);
}
return 0;
}