- Ejecutores
-
Aprender
Aprender Python Ejemplos ejecutables, NumPy, pandas y más Aprender IARedes neuronales, ML y LLM desde cero Aprender C y C++ Punteros, memoria, STL y C++ moderno Aprender C#Fundamentos, POO, LINQ, async y ejercicios de .NET Aprender MatplotlibGráficos de líneas, barras, dispersión y sectores con visualizadores Aprender RustOwnership, traits, manejo de errores e hilos Aprender GoSlices, interfaces, goroutines y canales Algoritmos en Python Búsqueda, ordenación, recursión y visualizadores O(n) Algoritmos en C y C++ Compara implementaciones en C y C++ Programación para niños ¡Aprende a programar jugando!
- RetosNuevo
- Para docentesNuevo
- Actualizaciones
- Invítame a un café
Structs, enums y traits
Modela datos con structs y enums, compara patrones, maneja Option y Result, y comparte comportamiento con traits y genéricos.
- Lección 1 reto Structs Group related values into your own type with named fields.
- Lección 2 retos Methods and impl Blocks Attach functions to a struct with impl, including constructors.
- Lección 1 reto Enums Define a type that is one of several variants, each with its own data.
- Lección 2 retos Pattern Matching with match Compare a value against patterns with match, guards and if let.
- Lección 1 reto Temperature Converter Convert between Celsius and Fahrenheit with an enum.
- Lección 2 retos Option: Values That May Be Missing Represent a missing value with Option instead of null.
- Lección 2 retos Error Handling with Result Return errors as values with Result and pass them on with the ? operator.
- Lección 1 reto Bank Account with Result Model deposits and withdrawals that can fail with your own error type.
- Lección 1 reto Traits Describe shared behavior with a trait and implement it for different types.
- Lección 1 reto Generics Write one function or struct that works with many types.