why second scanf is skipping
this one
#include
int main()
{
int l;
int k;
int j;
printf("Hi i am alex\n");
printf("How are u sharad\n");
scanf("%d", &l);
if ("I am fine")
{
printf("Me too!\n");
}
printf("What u was doing?\n");
printf("Before talking with me!\n");
scanf("%d", &k);
if ("ok")
{
printf("I was sleeping");
};
return 0;
}
Answers
Answered by
1
Hey there, your program contains some errors. Write this code given below.
#include <stdio.h>
int main()
{
int l;
int k;
int j;
printf("Hi i am alex\n");
printf("How are u?\n");
scanf("%d", &l);
if ("I am fine")
{
printf("Me too!\n");
}
printf("What u was doing?\n");
printf("Before talking with me!\n");
scanf("%d", &k);
if ("ok")
{
printf("I was sleeping");
};
return 0;
}
Similar questions