Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please this is my third time posting this question, the first answer i get was incomplete and didnt match the expected outcome same apply to

Please this is my third time posting this question, the first answer i get was incomplete and didnt match the expected outcome same apply to the second answer. Please help me look at it careful and thanks for your help.

C++

Instructions

Write a program that uses for loops to perform the following steps:

  1. Prompt the user to input two integers: firstNum and secondNum
    • (firstNum must be less than secondNum).
  2. Output all odd numbers between firstNum and secondNum.
  3. Output the sum of all even numbers between firstNum and secondNum.
  4. Output the numbers and their squares between 1 and 10.
    • Separate the numbers using any amount of spaces.
  5. Output the sum of the square of the odd numbers between firstNum and secondNum.
  6. Output all uppercase letters.

#include

using namespace std;

int main() {

// Write your main here

return 0;

}

TEST CASE

Output all odd numbers between firstNum and secondNum case 1

Expected Output

5 7 9 11 13 15 17 19 21 23 25 27 29 31 33 35

Output all odd numbers between firstNum and secondNum case 2

Expected Output

987 989 991 993 995 997 999 1001

Output the numbers and their squares between 1 and 10 case 1

Expected Output

1 1 2 4 3 9 4 16 5 25 6 36 7 49 8 64 9 81 10 100

Output the numbers and their squares between 1 and 10 case 2

Expected Output

1 1 2 4 3 9 4 16 5 25 6 36 7 49 8 64 9 81 10 100

Output all uppercase letters case 1

Expected Output

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Output all uppercase letters case 2

Expected Output

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Data Analysis Using SQL And Excel

Authors: Gordon S Linoff

2nd Edition

111902143X, 9781119021438

More Books

Students also viewed these Databases questions