Great Deal! Get Instant $10 FREE in Account on First Order + 10% Cashback on Every Order Order Now

More detail in the attached: Instructions Write a program that useswhileloops to perform the following steps: Prompt the user to input two integers:firstNumandsecondNum (firstNummust be less...

1 answer below »

More detail in the attached:

Instructions

Write a program that useswhileloops to perform the following steps:

  1. Prompt the user to input two integers:firstNumandsecondNum
    • (firstNummust be less thansecondNum).
  2. Output all odd numbers betweenfirstNumandsecondNum.
    • Separate each number with a space
  3. Output the sum of all even numbers betweenfirstNumandsecondNum.
  4. Output the numbers and their squares between1and10.
  5. Output the sum of the square of the odd numbers betweenfirstNumandsecondNum.
  6. Output all uppercase letters.
    • Separate each letter with a space
Answered 1 days After Oct 22, 2021

Solution

Sathishkumar answered on Oct 24 2021
131 Votes
#include #include using namespace std;
int firstnum,secondnum;
int main()
{
int x=1;
while(x==1)
{
*Question--1*
cout
"Enter the first number: "
endl;
cin
firstnum;
cout
"Enter the second number: "
endl;
cin
secondnum;
*Question--*
cout
"Odd numbers in range of "
firstnum
" and "
secondnum
endl;
Odd numbe
for(int i = firstnum; i <= secondnum; i++)
{
    if ( i % 2 != 0 )
    {
...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here