C , IF e Else!
an anonymous user
·
#include <stdio.h> #include <stdlib.h> int main() { int num; printf (“Digite um numero: “); scanf (“%d”,&num) if (num>0) { printf (“\n\nO numero e positivo\n”; } else { printf (“O numero e negativo”); } return 0; }
Output
(Run the program to view its output)
Comments