Daily Python Tips retweeted
Python is the #1 programming language in the world: bit.ly/2eNNcO9 - Proud to be part of this wonderful community. #positivepython
zip(zero or more) function allows you to iterate over number of iterables. #Python
You can concatenate list of string using String join() method #Python
filter (function,iterable) - evaulate given iterable against a condition and creates new iterable with items passing that condition. #Python
map() creates a new iterable by applying a given function to every element of the source iterable. #Python
Using timedelta to find the differences between dates in #Python.
Try using strftime function to convert python date-time object to string. #Python
Generators are iterators where the values are generated at the time of need without creating or saving all items. #Python
Try using built-in method 'enumerate' for any iterables in #Python.
Python treats mutable default arguments in function definitions differently #Python
Here comes both good and bad practice.
Try using two leading underscores ( __x ), to define private class variables. #Python
If there is no any exceptions at TRY clause, the ELSE clause will be executed. #Python
Using compound statements in #Python is a good practice!
Empty list ([ ]), zero (0), float zero ( 0.0 ), None and Empty String ( "") always evaluate to False. #Python
Try to use all CAPS_AND_UNDERSCORE to identify constants in #python
Checking whether two objects (lists, dictionaries, custom objects) you created are equal or not is called a test of identity in #Python.
Use get() method in #Python's dictionary to return a default value if key is not found. #programming
Comparisons can be chained arbitrarily in #python.
x < y <= z
is equivalent to
x < y and y <= z




















