-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlopp.cpp
More file actions
34 lines (32 loc) · 820 Bytes
/
Copy pathlopp.cpp
File metadata and controls
34 lines (32 loc) · 820 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#include <iostream>
#include <cstdio>
using namespace std;
void detect(int numero){
if(numero >=1 && numero <=9){
if(numero == 1){cout<<"one"<<endl;}
if(numero == 2){cout<<"two"<<endl;}
if(numero == 3){cout<<"three"<<endl;}
if(numero == 4){cout<<"four"<<endl;}
if(numero == 5){cout<<"five"<<endl;}
if(numero == 6){cout<<"six"<<endl;}
if(numero == 7){cout<<"seven"<<endl;}
if(numero == 8){cout<<"eight"<<endl;}
if(numero == 9){cout<<"nine"<<endl;}
}
if(numero > 9){
if(numero % 2 == 0){
cout<<"even"<<endl;
}else{
cout<<"odd"<<endl;
}
}
}
int main() {
int a, b;
cin>>a;
cin>>b;
for(int numero = a; numero <= b; numero++){
detect(numero);
}
return 0;
}