ask user for a number greater than 100 if the user doesn't follow firections display an error if the number is greater than 200 multiply it by itself and display "your number squared is ##" 50 times on 50 different line
1
Expert's answer
2013-02-13T11:23:27-0500
#include <conio.h> #include <iostream>
using namespace std;
int main() { int number; cout << " Enter a number greater than 100: "; cin >> number;
if (number < 100) cout << " Wrong number."; else if (number > 200) { number *= number; for (char c = 0; c < 50; c++) cout << " Your number squared is " << number << endl; } _getch(); return 0; }
Numbers and figures are an essential part of our world, necessary for almost everything we do every day. As important…
APPROVED BY CLIENTS
"assignmentexpert.com" is professional group of people in Math subjects! They did assignments in very high level of mathematical modelling in the best quality. Thanks a lot
Comments
Leave a comment