You are on page 1of 1

/******************************************************************************

Online C++ Compiler.


Code, Compile, Run and Debug C++ program online.
Write your code in this editor and press "Run" button to compile and execute it.

*******************************************************************************/

#include <iostream>

using namespace std;

int main()
{
double numero;
cout << "Introduce un número: ";
cin >> numero;

if (numero >= 0) {
cout << "El número " << numero << " es positivo.";
} else {
cout << "El número " << numero << " es negativo.";
}
}

You might also like