rafaym's picture
feat(es): add Spanish coding exercises (Tier 1-3)
e428ce5 verified
# Spanish (Español) - Legesher Python
## Getting Started
### Run the Hello World Example
```bash
legesher run languages/es/hello_world.py --lang es
```
### Translate Between Languages
```bash
# Spanish to English
legesher translate languages/es/hello_world.py --from es --to en
# English to Spanish
legesher translate languages/en/hello_world.py --from en --to es
```
## Files in This Folder
| File | Description |
|------|-------------|
| `hello_world.py` | Simple example program in Spanish |
| `REFERENCE.md` | Complete keyword and builtin reference |
## Coding Exercises
Practice writing Legesher Python in Spanish with these tiered exercises.
### Tier 1 — Basic (⭐)
| File | Exercise | Difficulty | Time |
|------|----------|------------|------|
| `exercises/tier1/juego_del_7.py` | El Juego del 7 — FizzBuzz-style counting game | ⭐ | 10 min |
| `exercises/tier1/factorial.py` | Factorial — recursive factorial function | ⭐ | 10 min |
| `exercises/tier1/palindromo.py` | Palíndromo — palindrome check | ⭐ | 10 min |
| `exercises/tier1/ordenamiento.py` | Ordenamiento — bubble sort without builtins | ⭐⭐ | 15 min |
```bash
legesher run languages/es/exercises/tier1/juego_del_7.py --lang es
```
### Tier 2 — Applied (⭐⭐)
| File | Exercise | Difficulty | Time |
|------|----------|------------|------|
| `exercises/tier2/analizador.py` | Analizador de Archivos — CSV file parser | ⭐⭐ | 20 min |
| `exercises/tier2/frase_del_dia.py` | Cliente API Simple — daily quote API client | ⭐⭐⭐ | 25 min |
| `exercises/tier2/transformador.py` | Transformador de Datos — JSON grade converter | ⭐⭐ | 25 min |
| `exercises/tier2/calculadora.py` | Calculadora — interactive calculator | ⭐⭐ | 25 min |
```bash
legesher run languages/es/exercises/tier2/calculadora.py --lang es
```
### Tier 3 — Domain-specific (⭐⭐⭐)
| File | Exercise | Difficulty | Time |
|------|----------|------------|------|
| `exercises/tier3/fifa_rating.py` | Análisis de Datos — custom FIFA rating system | ⭐⭐⭐ | 40 min |
| `exercises/tier3/raspador.py` | Raspador Web — HTML scraper (marca.com) | ⭐⭐⭐⭐ | 60 min |
| `exercises/tier3/piedra_papel_tijera.py` | Piedra, Papel, Tijera — multi-round game | ⭐⭐⭐ | 45 min |
| `exercises/tier3/cribo.py` | Cribo de Eratóstenes — prime number sieve | ⭐⭐⭐ | 40 min |
```bash
legesher run languages/es/exercises/tier3/fifa_rating.py --lang es
```
## Quick Reference
See [REFERENCE.md](./REFERENCE.md) for the complete list of keyword and builtin translations.
## Need Help?
- [Main Tutorial](../../docs/tutorials/TUTORIAL.md) - Detailed instructions
- [Documentation](https://docs.legesher.io) - Full documentation