Welcome to AssignmentCache!

PRG/420 Week 4 Java 4.16 LAB: Two smallest numbers

Availability: In stock

$7.00

Quick Overview

PRG/420 Week 4 Java 4.16 LAB: Two smallest numbers


Write a program that reads a list of integers, and outputs the two smallest integers in the list, in ascending order. The input begins with an integer indicating the number of integers that follow. You can assume that the list will have at least 2 integers and fewer than 20 integers.


Ex: If the input is:
5 10 5 3 21 2
the output is:
2 3
To achieve the above, first read the integers into an array.
Hint: Make sure to initialize the second smallest and smallest integers properly.

PRG420 Week 4 Java 4.16 LAB Two smallest numbers

Double click on above image to view full picture

Zoom Out
Zoom In

More Views

  • PRG420 Week 4 Java 4.16 LAB Two smallest numbers
$7.00

Details

PRG/420 Week 4 Java 4.16 LAB: Two smallest numbers

Write a program that reads a list of integers, and outputs the two smallest integers in the list, in ascending order. The input begins with an integer indicating the number of integers that follow. You can assume that the list will have at least 2 integers and fewer than 20 integers.

Ex: If the input is:
5 10 5 3 21 2
the output is:
2 3
To achieve the above, first read the integers into an array.
Hint: Make sure to initialize the second smallest and smallest integers properly.

Additional Information

Special Price $3.00

Product Tags

Use spaces to separate tags. Use single quotes (') for phrases.

[profiler]
Memory usage: real: 18350080, emalloc: 17917360
Code ProfilerTimeCntEmallocRealMem