Advertisement
teslariu

matriz

May 27th, 2021
117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. # IMPRESION DE MATRICES
  4.  
  5. notas = [["pepe",10], ["ana",5], ["tito",8]]
  6.  
  7. print("impresiĆ³n horizontal de la matriz notas")
  8. print(notas)
  9.  
  10. print("\nimpresiĆ³n de los elementos de la matriz nota")
  11. for alumno in notas:
  12. print(alumno[0], alumno[1])
  13.  
  14. print("\nImpresion vertical de los elementos de la matriz notas")
  15. for alumno in notas:
  16. for elemento in alumno:
  17. print(elemento)
  18.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement