axbycz

mail@pastecode.io avatar
unknown
plain_text
2 years ago
554 B
29
Indexable
Never
#include<iostream>
using namespace std;

string docso(long so){
	switch(so){
		case 0:return "Khong ";
		case 1:return "Mot ";
		case 2:return "Hai ";
		case 3:return "Ba ";
		case 4:return "Bon ";
		case 5:return "Nam ";
		case 6:return "Sau ";
		case 7:return "Bay ";
		case 8:return "Tam ";
		case 9:return "Chin ";
	}
	return 0;
}
int main(){
	int so, du;
	string chuoi=docso(du)+chuoi;
	cout<<"Nhap so tu nhien = ";cin>>so;
	cout<<so<<" doc la: ";
	while(so!=0){
		du=so%10;
		cout<<docso(du);
		so=so/10;
	}
return 0;
}