package experimento2;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
public class Experimento2 {
Discotienda discotienda = new Discotienda();
CD cd = new CD();
int opcion;
do
{
System.
out.
println("Buenos días, ¿Qué desea hacer?"); System.
out.
println("1. Registrar datos de la Discotienda"); System.
out.
println("2. Agregar CD's al inventario"); System.
out.
println("3. Salir"); opcion
= Integer.
parseInt(lector.
readLine());
switch (opcion)
{
case 1:
System.
out.
println("Ingrese el nombre de la Discotienda"); String nombre
= lector.
readLine(); System.
out.
println("Ingrese la dirección del establecimiento"); String direccion
= lector.
readLine(); System.
out.
println("Ingresar un teléfono(s)"); discotienda.telefono();
System.
out.
println("Ingrese el nombre de un empleado(s)"); discotienda.empleado();
break;
case 2:
cd.album();
}
}while(opcion!=3);
}
}
cGFja2FnZSBleHBlcmltZW50bzI7CgppbXBvcnQgamF2YS5pby5CdWZmZXJlZFJlYWRlcjsKaW1wb3J0IGphdmEuaW8uSU9FeGNlcHRpb247CmltcG9ydCBqYXZhLmlvLklucHV0U3RyZWFtUmVhZGVyOwoKCnB1YmxpYyBjbGFzcyBFeHBlcmltZW50bzIgewoKCQogICAgcHVibGljIHN0YXRpYyB2b2lkIG1haW4oU3RyaW5nW10gYXJncykgdGhyb3dzIEV4Y2VwdGlvbiB7CiAgICAgICAgCiAgICAgICAgRGlzY290aWVuZGEgZGlzY290aWVuZGEgPSBuZXcgRGlzY290aWVuZGEoKTsKICAgICAgICBDRCBjZCA9IG5ldyBDRCgpOwogICAgICAgICAgICAgICAgCiAgICAgICAgaW50IG9wY2lvbjsKICAgICAgICAKCQlkbyAgICAgICAgICAgICAgCiAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgIHsKCQkJU3lzdGVtLm91dC5wcmludGxuKCJCdWVub3MgZMOtYXMsIMK/UXXDqSBkZXNlYSBoYWNlcj8iKTsKCQkJU3lzdGVtLm91dC5wcmludGxuKCIxLiBSZWdpc3RyYXIgZGF0b3MgZGUgbGEgRGlzY290aWVuZG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