Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (define (cargar-datos ubicacion)
- (local
- (
- (define (cargarEmpleados listaEmpleados)
- (cond
- [(empty? listaEmpleados) empty]
- [(not (cons? listaEmpleados)) "Porfavor cargue una lista"]
- [(cons? (first listaEmpleados))
- (cons (make-empleado
- (make-datos-persona (first (first listaEmpleados)) (second (first listaEmpleados)) (third (first listaEmpleados)) )
- (string->number (fourth (first listaEmpleados)))
- ) (cargarEmpleados (rest listaEmpleados))
- )]
- [else (error "Error al cargar los empleados. Por favor intente de nuevo.")]
- ))
- (define listaEmpleados empty)
- )
- (cargarEmpleados (read-words/line ubicacion))
- ))
- (define listaEmpleados (cargar-datos "Data/Empleados.txt"))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement