Ejercicio de repaso para el primer parcial.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import "fmt" | |
type Humano interface { | |
Vivir() | |
} | |
type Alumno struct { | |
Legajo string |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import csv | |
import pickle | |
def calcular_cuotas(archivo_entrada, archivo_salida, valor_cuota): | |
''' Ejercicio 1 ''' | |
with open(archivo_entrada, 'r') as entrada, open(archivo_salida, 'w') as salida: | |
escritor = csv.writer(salida, quoting=csv.QUOTE_NONNUMERIC) | |
escritor.writerow(["Nombre", "Nro de Socio", "Categoría", |
Se tiene un diccionario carreras
que tiene como clave el nombre de una carrera y como contenido una lista de materias. Por ejemplo, podemos tener:
carreras = {
“música”: [“historia”, “piano 1”, “piano 2”, “guitarra”, “composición”],
“pintura”: [“historia”, “dibujo 1”, “dibujo 2”, “pintura 1”, “pintura 2”]
}
Se tiene también un diccionario alumnos
, cuya clave es el legajo y como datos una tupla con nombre, lista de carreras en las que está inscripto y un diccionario con clave nombre de la materia y lista de notas (puede aparecer más de una nota solamente si el alumno no aprobó la materia la primera vez). Por ejemplo:
NewerOlder