Advertisement
dizzy94

Untitled

Apr 22nd, 2018
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.44 KB | None | 0 0
  1. package geometria;
  2.  
  3. import java.util.Set;
  4. import java.util.TreeSet;
  5.  
  6. public class Rysuenk {
  7. public static void main(String[] args) {
  8. Set<Figura> figury = new TreeSet<>();
  9. figury.add(new Kolo(3.0, 1.0, 4.0));
  10. figury.add(new Kwadrat(4, 2, 2));
  11. figury.add(new Prostokat(2.0, 4.0, 3.0, 3.0));
  12.  
  13. for (Figura x: figury
  14. ) {
  15. System.out.println(figury);
  16. }
  17.  
  18. }
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement