-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
53 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Show me some examples of type aliasing in Python try to give examples for all | ||
|
||
# 1. Type aliasing for built-in types | ||
# 2. Type aliasing for user-defined types | ||
# 3. Type aliasing for generic types | ||
# 4. Type aliasing for generic types with type parameters | ||
# 5. Type aliasing for generic types with type parameters and constraints | ||
# 6. Type aliasing for generic types with type parameters and constraints and default values | ||
# 7. Type aliasing for generic types with type parameters and constraints and default values and type parameters | ||
# 8. Type aliasing for generic types with type parameters and constraints and default values and type parameters and constraints | ||
# 9. Type aliasing for generic types with type parameters and constraints and default values and type parameters and constraints and default values | ||
# 10. Type aliasing for generic types with type parameters and constraints and default values and type parameters and constraints and default values and type parameters | ||
# 11. Type aliasing for generic types with type parameters and constraints and default values and type parameters and constraints and default values and type parameters and constraints | ||
# 12. Type aliasing for generic types with type parameters and constraints and default values and type parameters and constraints and default values and type parameters and constraints and default values | ||
# 13. Type aliasing for generic types with type parameters and constraints and default values and type parameters and constraints and default values and type parameters and constraints and default values and type parameters | ||
# 14. Type aliasing for generic types with type parameters and constraints and default values and type parameters and constraints and default values and type parameters and constraints and default values and type parameters and constraints | ||
|
||
type Alias1 = int | ||
type Alias2 = str | ||
type Alias3 = float | ||
|
||
type AliasWithParams1[T] = T | ||
type AliasWithParams2[T] = T | ||
|