Create an array named nums with a datatype of integer

Assignment Help Computer Engineering
Reference no: EM133914882

Homework

The goal of this homework is for you to construct a Java application that will prompt the user for input, store that input in an array, sort the inputted data, and output the sorted data on screen. This will be accomplished using the built-in Java libraries. (Later in the course you will write the sorting algorithm yourself.) These instructions are very specific, which reflects real-world customer requirements, so please follow them carefully.

Below in the editing window you can see a line that reads "Type your code below this line. Create additional lines as needed." All your code will go below that line, but before the first line with the comment "do not delete this line". Based on the Unit 1 Learning Activities, follow the steps below to construct your program:

Part I: Arrays and Variables

1. Create the Scanner variable with the following code: Scanner input = new Scanner(System.in);
2. Create an array named "nums", with a datatype of Integer (int) and a size of 3.

Part II: Input and User Prompts

1. Prompt the user with the following text (exactly): Input a number between 6 and 10
2. Store the user's input in the first position of the nums array (index 0).
3. Prompt the user with the following text: Input a number between 11 and 15
4. Store the user's input in the second position of the nums array (index 1).
5. Prompt the user with the following text: Input a number between 1 and 5
6. Store the user's input in the third position of the nums array (index 2).

Part III: Confirmation

Confirm the user's data by displaying it on the screen in the following way, with the appropriate user data displayed after the colon on each line:

Displaying unsorted array:
First number entered:
Second number entered:
Third number entered:

Part IV: Sorting the Array

i. Inform the user of what you are doing with the following message: "Sorting numbers...". Get the instant assignment help.
ii. Sort the array using the sort method built into the Arrays class with this code: Arrays.sort(nums);

Part V: Output

Display the user's data on the screen in the following way, with the appropriate data values displayed after the colon on each line:

Displaying sorted array:
Lowest number:
Middle number:
Highest number:

Reference no: EM133914882

Questions Cloud

Create hypothetical scenario discussing the design principle : Create a hypothetical scenario discussing the design principles that should be considered to ensure the security of user transactions and personal information.
Explore the functionalities of the security monitoring tools : Explore the purpose and functionalities of the security monitoring tools you identified in Week 2 Discussion as they apply to project management.
Develop transformational leadership skills : Describe the leadership and management principles needed to develop transformational leadership skills.
Identify strategic change initiative success factors : Identify strategic change initiative success factors and discuss how these factors impact successful system implementation.
Create an array named nums with a datatype of integer : Create the Scanner variable with the following code: Scanner input = new Scanner. Create an array named nums, with a datatype of Integer (int) and a size of 3.
Learning management system : Learning Management System - Materials submitted to fulfill requirements in one course may not be submitted in another course.
Assessing your awareness of global ethical principles : Assessing your awareness of global ethical principles, ethical concerns in the tourism business workplace.
Evaluate the risks associated with capital markets : Evaluate the risks associated with capital markets using financial tools-such as return distributions, ratios, and risk measures-and applies these tools
Define data analysis techniques : Define data analysis techniques such: as emergent coding themes, interpretations and representations Explain the 4 types of triangulation

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd