Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static void main(String[] args) {
- int [] temprature = {9,8,5,13,7,17,5,14,9,5,18};
- for (double ar : temprature) {
- System.out.println(ar);
- }
- Collections.sort(temprature);
- for (double ar : temprature) {
- System.out.println(ar); }
- Collections.reverse(temprature);
- for (double ar : temprature) {
- System.out.println(ar); }
- }
Add Comment
Please, Sign In to add comment