Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <iomanip>
- #include <conio.h>
- using namespace std;
- /*De 10 números ingresados indicar
- cuantos son mayores a cero y
- cuantos son menores a cero.*/
- int detectar_num(int x){
- int y;
- y=x;
- if (y>0){
- cout<<y<<" Es mayor a 0."<<endl;
- }
- else{
- cout<<y<<" Es menor a 0."<<endl;
- }
- return y;
- }
- int main(){
- int a,b,c,d,e;
- int f,g,h,i,j;
- int q,r,s,t,u;
- int v,w,x,y,z;
- cin>>a>>b>>c>>d>>e>>f>>g>>h>>i>>j;
- q=detectar_num(a);
- r=detectar_num(b);
- s=detectar_num(c);
- t=detectar_num(d);
- u=detectar_num(e);
- v=detectar_num(f);
- w=detectar_num(g);
- x=detectar_num(h);
- y=detectar_num(i);
- z=detectar_num(j);
- _getch();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement