How JustAnswer Works:
  • Ask an Expert
    Experts are full of valuable knowledge and are ready to help with any question. Credentials confirmed by a Fortune 500 verification firm.
  • Get a Professional Answer
    Via email, text message, or notification as you wait on our site.
    Ask follow up questions if you need to.
  • 100% Satisfaction Guarantee
    Rate the answer you receive.
Ask TheDoctor Your Own Question
TheDoctor, Professional w/Adv. Degree
Category: Homework
Satisfied Customers: 1757
Experience:  M.S. in Internet Information Systems
Type Your Homework Question Here...
TheDoctor is online now
A new question is answered every 9 seconds

Write a Java application that allows a user to enter 10 numbers

This answer was rated:

Write a Java application that allows a user to enter 10 numbers (double precision) into an array and then sorts and displays the numbers from lowest to highest. You should use the Arrays.sort() method. Demonstrate your code compiles and runs without issue
Hello and thank you for your question. It would be my pleasure to assist you.

I will contact you once this is complete.
Hello again!

You can download the completed task here:

Unzip the file and you will find the java file, the compiled class, and a Microsoft Word document.

In the Microsoft Word document is a screen shot of the program functioning. I am sending you this because your request states that you are to provide evidence of the project working.

If you would like to run the application yourself, you must compile it and run it like this:


java DoubleSort

Those are command-line arguments for compiling and running a Java program. Doing this requires that you have already set up JDK and have Java on your system path variables. This would have been part of the set up at the very beginning of your course.

I included exception handling, which your instructor should greatly appreciate. Good programs have exception handling.

I have also fully commented the code for your benefit and because instructors tend to require it.

Let me know if you have any questions at all. I'm here to help.

If you ever need assistance in the future, please feel free to request me directly by starting your questions with **For TheDoctor**.

Please remember to rate my answer. Thank you so much and have a wonderful day!
Customer: replied 4 years ago.

The .class file is not opening. Can you do it so I can just copy and paste into Netbeans please.

You cannot open a class file. That is a compiled file.

I will send you a project that you can import into Netbeans. I will have that to you shortly.

Hello again,

Here is an exported Netbeans project:

Do not unzip this file.

In Netbeans, go to File->Import Project->From Zip...

Click on the browse button for zip file and select this zip. The second browse button is so you can select where to save the project to.

Click the import button and that is it. You now have a Netbeans project with the code.

If you right-click on the project name (Sort) and select run, it will run in the console at the bottom of the IDE.


If you would like to just copy and paste into an existing Netbeans project, then open up (that is the code file, not .class. .class files are compiled files). You can open the .java file in any text editor. If you want to copy the code from that file into your own project, you can do so. Keep in mind that the class name isXXXXX that needs to be the name of the file if you attempt to do the copy/paste. Otherwise, change the class name in the code.

Let me know if you have any other questions.

Please remember to rate my answer. Thank you again.

TheDoctor and 4 other Homework Specialists are ready to help you

You need to spend $3 to view this post. Add Funds to your account and buy credits.

Related Homework Questions