Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Which XXX and YYY will output the sum of the input integers ( stopping when - 1 is input ) ? Flowchart has 2 variables

Which XXX and YYY will output the sum of the input integers (stopping when -1 is input)?
Flowchart has 2 variables (integer val, integer sum) and 8 nodes. Node 1 is the start node and points to node 2. Node 2 code: val = Get next input Node 2 points to node 3. Node 3 code: XXX Node 3 points to node 4. Node 4 code: while not(val ==-1) Node 4 points to nodes 5(condition is true) and 7(condition is false). Node 5 code: YYY Node 5 points to node 6. Node 6 code: val = Get next input Node 6 points to node 4. Node 7 code: Put sum to output Node 7 points to node 8. Node 8 is the end node.
a.
XXX: sum = val / YYY: sum = val
b.
XXX: sum = val / YYY: sum = sum + val
c.
XXX: sum =0/ YYY: sum = sum + val
d.
XXX: sum =0/ YYY: sum = val

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

SQL Server Query Performance Tuning

Authors: Sajal Dam, Grant Fritchey

4th Edition

1430267429, 9781430267423

More Books

Students also viewed these Databases questions

Question

3. Give examples of four fair disciplinary practices.

Answered: 1 week ago

Question

6. Explain how to train managers to coach employees.

Answered: 1 week ago

Question

5. Tell how job experiences can be used for skill development.

Answered: 1 week ago

Question

4. Explain the characteristics of successful mentoring programs.

Answered: 1 week ago