tareando
parent
56eccff819
commit
320f4f7122
|
|
@ -0,0 +1,16 @@
|
|||
# Música by Juanposo
|
||||
Página que muestre mi amor a la música así bien moderno y pulento, cómo debe tener 5 páginas podrían ser algo así:
|
||||
## 1. Index - Introducción
|
||||
## 2. Cómo escuchar música en la era moderna
|
||||
Hablar de distintos streaming, cosas cómo Jellyfin, aplicaciones para escuchar música, RYM, vinílos, CDs y todo lo demás.
|
||||
## 3. Mis artistas favoritos
|
||||
- Daft Punk
|
||||
- Kendrick Lamar
|
||||
- Outkast
|
||||
- Radiohead
|
||||
## 4. Mis Discos favoritos
|
||||
- To Pimp a Butterfly
|
||||
- In Rainbows
|
||||
- Discovery
|
||||
- Love Deluxe
|
||||
## 5. Recomendaciones
|
||||
Binary file not shown.
|
|
@ -70,18 +70,6 @@
|
|||
"display_name": "Python 3 (ipykernel)",
|
||||
"language": "python",
|
||||
"name": "python3"
|
||||
},
|
||||
"language_info": {
|
||||
"codemirror_mode": {
|
||||
"name": "ipython",
|
||||
"version": 3
|
||||
},
|
||||
"file_extension": ".py",
|
||||
"mimetype": "text/x-python",
|
||||
"name": "python",
|
||||
"nbconvert_exporter": "python",
|
||||
"pygments_lexer": "ipython3",
|
||||
"version": "3.14.0"
|
||||
}
|
||||
},
|
||||
"nbformat": 4,
|
||||
|
|
|
|||
|
|
@ -2,76 +2,48 @@
|
|||
"cells": [
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 2,
|
||||
"id": "ba90127a",
|
||||
"execution_count": null,
|
||||
"id": "efcea9bf",
|
||||
"metadata": {},
|
||||
"outputs": [
|
||||
{
|
||||
"name": "stdout",
|
||||
"output_type": "stream",
|
||||
"text": [
|
||||
"Texto decodificado:\n",
|
||||
"MI PINGA ESTA EN SU MAXIMA EXPRESION\n"
|
||||
"CIERTO DIA DE VERANO ESTABA EN LA PLAYA OBSERVANDO DOS CHICAS BRINCANDO EN LA ARENA, ESTABAN TRABAJANDO MUCHO CONSTRUYENDO UN CASTILLO DE ARENA CON TORRES, PASADIZOS OCULTOS Y PUENTES\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"def Valida_Entrada(texto):\n",
|
||||
" \"\"\"\n",
|
||||
" Valida que la entrada cumpla las siguientes condiciones:\n",
|
||||
" - Longitud máxima de 1000 caracteres.\n",
|
||||
" - Solo contiene letras, dígitos, espacios, comas y/o puntos.\n",
|
||||
" \"\"\"\n",
|
||||
" if len(texto) > 1000:\n",
|
||||
" return False\n",
|
||||
"codigo = input(\"Indica un código indescifrable\")\n",
|
||||
"codigo = codigo.upper()\n",
|
||||
"\n",
|
||||
" for c in texto:\n",
|
||||
" if not (c.isalnum() or c in [' ', ',', '.']):\n",
|
||||
" return False\n",
|
||||
"def validar_entrada():\n",
|
||||
" if len(texto)<1000:\n",
|
||||
" return True\n",
|
||||
"\n",
|
||||
" return True\n",
|
||||
"def decodificador (a):\n",
|
||||
" i = 0\n",
|
||||
" texto = codigo\n",
|
||||
" while i < len(texto):\n",
|
||||
" if texto[i] == \"1\":\n",
|
||||
" texto = texto.replace(\"1\",\"I\")\n",
|
||||
" elif texto[i] == \"3\":\n",
|
||||
" texto = texto.replace(\"3\",\"E\")\n",
|
||||
" elif texto[i] == \"4\":\n",
|
||||
" texto = texto.replace(\"4\",\"A\")\n",
|
||||
" elif texto[i] == \"5\":\n",
|
||||
" texto = texto.replace(\"5\",\"S\")\n",
|
||||
" elif texto[i] == \"7\":\n",
|
||||
" texto = texto.replace(\"7\",\"T\")\n",
|
||||
" elif texto[i] == \"8\":\n",
|
||||
" texto = texto.replace(\"8\",\"B\")\n",
|
||||
" elif texto[i] == \"0\":\n",
|
||||
" texto = texto.replace(\"0\",\"O\")\n",
|
||||
" i = i + 1\n",
|
||||
" return(texto)\n",
|
||||
"\n",
|
||||
"\n",
|
||||
"def Decodifica(texto):\n",
|
||||
" \"\"\"\n",
|
||||
" Reemplaza los dígitos por las letras según la tabla:\n",
|
||||
" 1→I, 3→E, 4→A, 5→S, 7→T, 8→B, 0→O\n",
|
||||
" \"\"\"\n",
|
||||
" reemplazos = {\n",
|
||||
" '1': 'I',\n",
|
||||
" '3': 'E',\n",
|
||||
" '4': 'A',\n",
|
||||
" '5': 'S',\n",
|
||||
" '7': 'T',\n",
|
||||
" '8': 'B',\n",
|
||||
" '0': 'O'\n",
|
||||
" }\n",
|
||||
"\n",
|
||||
" resultado = \"\"\n",
|
||||
" for c in texto:\n",
|
||||
" if c in reemplazos:\n",
|
||||
" resultado += reemplazos[c]\n",
|
||||
" else:\n",
|
||||
" resultado += c\n",
|
||||
" return resultado\n",
|
||||
"\n",
|
||||
"\n",
|
||||
"# -------------------- Programa Principal --------------------\n",
|
||||
"\n",
|
||||
"def main():\n",
|
||||
" texto = input(\"Ingrese el texto codificado: \").upper()\n",
|
||||
"\n",
|
||||
" if not Valida_Entrada(texto):\n",
|
||||
" print(\"Error: la cadena contiene caracteres no permitidos o supera los 1000 símbolos.\")\n",
|
||||
" return\n",
|
||||
"\n",
|
||||
" texto_decodificado = Decodifica(texto)\n",
|
||||
" print(\"Texto decodificado:\")\n",
|
||||
" print(texto_decodificado)\n",
|
||||
"\n",
|
||||
"\n",
|
||||
"if __name__ == \"__main__\":\n",
|
||||
" main()"
|
||||
"print(decodificador(texto))"
|
||||
]
|
||||
}
|
||||
],
|
||||
|
|
@ -80,18 +52,6 @@
|
|||
"display_name": "Python 3 (ipykernel)",
|
||||
"language": "python",
|
||||
"name": "python3"
|
||||
},
|
||||
"language_info": {
|
||||
"codemirror_mode": {
|
||||
"name": "ipython",
|
||||
"version": 3
|
||||
},
|
||||
"file_extension": ".py",
|
||||
"mimetype": "text/x-python",
|
||||
"name": "python",
|
||||
"nbconvert_exporter": "python",
|
||||
"pygments_lexer": "ipython3",
|
||||
"version": "3.14.0"
|
||||
}
|
||||
},
|
||||
"nbformat": 4,
|
||||
|
|
|
|||
Loading…
Reference in New Issue