Python - recipes
- Append item to array
- Apply function to list
- Array length
- Block comment
- Break out of loop
- Check variable is defined
- Class definition
- Class function
- Concatenate two arrays
- Counter loop
- Create a list of integers
- Create key value container
- Django check object exists
- Django get domain current request
- Django redirect directly in urls.py
- Documentation comment
- Do loop while a condition is true
- Exception handling
- Filter Queryset on any of Django Q objects list
- Find index of item in array
- For each loop
- Function default parameter
- Get all fields in Django model
- Get first element array
- Get last element of array
- Hello world
- Highest value of array of numbers
- If condition do
- If else
- If, else if, else
- Increment variable by one
- Inline conditional
- Key value item count
- Key value key existence test
- key value list all keys
- key value list all values
- Loop until condition is true
- Lower case string
- Map over array
- Object inner function
- Object instantiation
- Open debug command line
- Prepend item to list
- Random integer in range
- Range of alphabet chacters
- Repeat string
- Reverse string
- Set maximum number of relations in ManyToManyField in Django form
- Single comment
- Singleton - one object instance for class
- Sort list of numbers
- Sort objects by function
- String concatenation
- String length
- String to lowercase
- String to uppercase
- Switch
- Test array contains item
- Test for expression in string