List of Python live templates
Use live templates to insert common constructs into your code, such as loops, conditions, declarations, or print statements.
This table summarizes the live templates that you can use with your Python code.
Abbreviation | Description | Template text |
---|---|---|
| Dict comprehension |
|
| Dict comprehension with 'if' |
|
| Generator comprehension |
|
| Generator comprehension with 'if' |
|
| List comprehension |
|
| List comprehension with 'if' |
|
| Set comprehension |
|
| Set comprehension with 'if' |
|
| Iterate (for ... in ...) |
|
| Iterate (for ... in enumerate) |
|
| if __name__ == '__main__' |
|
| Property getter |
|
| Property getter/setter |
|
| Property getter/setter/deleter |
|
| 'super(...)' call |
|
Thanks for your feedback!
Was this page helpful?