Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 2.13
- A) cin >> b >> c >> d >> e >> f;
- 2.14
- E) a * (x * x * x) + ;
- 2.21
- #include<iostream>
- using namespace std;
- int main()
- {
- cout<<"*********\n* *\n* *\n* *\n* *\n* *\n* *\n* *\n*********\n\n";
- cout<<" *** \n * * \n* *\n* *\n* *\n* *\n* *\n * * \n *** \n\n";
- cout<<" * \n *** \n*****\n * \n * \n * \n * \n * \n * \n\n";
- cout<<" * \n * * \n * * \n * * \n* *\n * * \n * * \n * * \n * \n\n";
- return 0;
- }
- 2.30
- #include<iostream>
- using namespace std;
- int main()
- {
- int weight = 0, height = 0, BMI = 0;
- cout << "How much do you weigh in pounds?";
- cin >> weight;
- cout << "What is your height in inches?";
- cin >> height;
- BMI = ((weight * 703)) / ((height * height));
- cout << "Your BMI is" << BMI;
- if (BMI <= 18.5) {
- cout << "You're underweight\n";
- }
- if ((BMI > 18.5) && (BMI <= 24.9)) {
- cout << "You're Normal\n";
- }
- if ((BMI > 25) && (BMI <= 29.9)) {
- cout << "You're overweight\n";
- }
- if (BMI > 30) {
- cout << "You're obese\n";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement