File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Applets and the fly likes To get Maximum and minimum value from an array Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Applets
Bookmark "To get Maximum and minimum value from an array" Watch "To get Maximum and minimum value from an array" New topic
Author

To get Maximum and minimum value from an array

Aayush Patel
Greenhorn

Joined: Apr 26, 2001
Posts: 21
Can anybody help me for finding maximum value and minimum value from an array of double values..i mean suppose there is an array of double values and now i want to find max and min value then is there any readymade method in double class or we have to define with our own...
Nathan Pruett
Bartender

Joined: Oct 18, 2000
Posts: 4121

Well, there is a method in the Math class that returns the max of two double values... so to get the max of an array of doubles, you would have to do something like this...



HTH,
-Nate


-Nate
Write once, run anywhere, because there's nowhere to hide! - /. A.C.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: To get Maximum and minimum value from an array
 
Similar Threads
An odd question...
max value of an array
second maximum value from the array
SiMpLe Program but......I still beginner
caluculating sum of all the numbers in a String