+ 1
#include <stdio.h> int main(){ int a; printf("enter any number =") ; scanf("%d", & a) ; if (a>0) printf ("%d is positive number
Why isn't running
7 odpowiedzi
+ 2
Maybe, try copying your code to the playground, saving it, and then posting a link to it in the description area of your post. Don't put the code in the question area like you currently have it and change the question to the actual question. Then maybe we can help you.
+ 2
Please avoid writing code in question. Rather save your code and share its link, or write the code in the Description, if the code is small (less than 10~15 lines).
Here's how to share a saved code link 👇
https://www.sololearn.com/post/75089/?ref=app
+ 1
You dont have use %d format specifier after any number
Your code should be like this:
#include<stdio.h>
int main(){
int a;
printf("Enter any number = %d",a);
scanf("%d",&a);
If(a>0)
{
printf("%d is a positive number",a);
}
return 0;
}
+ 1
Sorry for that Ipang
+ 1
🌟ᴀɴᴜʀᴀɢ🌟
No apology needed buddy ...
I didn't say we don't help him, just giving him a bit of tips to help his thread gain more relevant response 👌
+ 1
Ipang 😊😊🌟☺️☺️☺️😃😃😌😌
0
Try this 👇
#include <stdio.h>
int main(){
int a;
printf("enter any number : ") ;
scanf("%d", & a) ;
if (a>0){
printf ("It is a positive number");
}
return 0;
}