cpp_primer_plus/ch03/01.cpp

14 lines
302 B
C++
Raw Normal View History

2022-08-24 05:44:15 +08:00
# include <iostream>
using namespace std;
const int feet2inch = 12;
int main(){
int height;
cout << "Enter Your Height (feet): ";
cin >> height;
int inch = height / feet2inch;
int feet = height % feet2inch;
cout << "Your Height is " << inch << " inch " << feet << " feet" << endl;
return 0;
}