Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
- package com.kurs_java;
- import java.util.*;
- import java.lang.*;
- /**
- *
- * @author Jakub
- */
- public class zadanie18 {
- public static void main(String[] args){
- ArrayList<Integer> tablica = new ArrayList<>();
- for(int a = 0; a<9; a++){
- tablica.add((int)(Math.random()*10+1));
- }
- Collections.sort(tablica);
- Collections.reverse(tablica);
- System.out.println(tablica);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement