Advertisement
Guest User

Untitled

a guest
Aug 13th, 2017
458
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.20 KB | None | 0 0
  1. package examen1;
  2.  
  3. public class pruebaGrupo {
  4.  
  5.  
  6. @SuppressWarnings("rawtypes")
  7. public static void main(String[] args) {
  8. double[] notas1 = {4.7,10.0,5.7,4.0,7,2};
  9. double[] notas2 = {1.0,5.0,1.0,4.0,4.5};
  10. double[] notas3 = {5.0,5.0,10.0,7.0,5.0};
  11. double[] notas4 = {10.0,5.0,10.0,5.0,6.2};
  12. double[] notas5 = {3.0,2.0,1.0,4.0,4.9};
  13. alumno a1=new alumno("paquito","paquitonico@gmai.com",false,notas1,5);
  14. alumno a2=new alumno("luis","luisluis@gmail.com",true,notas2,4);
  15. alumno a3=new alumno("fran","franciscofran@gmail.co,",false,notas3,5);
  16. alumno a4=new alumno("pepe","pepito@gmail.com",false,notas4,5);
  17. alumno a5=new alumno("Javi","javielindio@gmail.com",true,notas5,5);
  18. alumno[] alumnos={a1,a2,a3,a4,a5};
  19. Grupo gp1 =new Grupo("Informatica", true, alumnos, 5);
  20. String medias=gp1.generarListadoMedias(alumnos,5);
  21. System.out.println("Las medias de los alumnos son: "+"\n"+medias);
  22. String mediasrepetidores=gp1.generarListadoRepetidores(alumnos, 5);
  23. System.out.println("\nLas medias de todos los alumnos repetidores son: "+"\n"+mediasrepetidores);
  24. double notamaxima=gp1.notaMaxima(alumnos,5);
  25. System.out.println("los nota maxima de todo el grupo es:"+notamaxima);
  26. }
  27.  
  28.  
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement