Python language has a unique comprehension syntax, which is equivalent to the existence of syntactic sugar. It can help you to write relatively simple and cool code in some occasions. […]
When we create python functions, sometimes we do not need to define python functions explicitly, and it is more convenient to pass them into anonymous functions directly. This saves us […]
For various reasons, we will need to install many versions of Python interpreter under the same operating system. We may also need different versions of same module for various reasons […]
Usually in Python, we use multi-threading or multi-processing to implement concurrent programming. Computing-intensive tasks for cpu are usually implemented by multi-processor because of GIL, while io-intensive tasks can be scheduled […]
Python requests module is a http client library, which is similar to urllib and urllib2. It is more convenient than urllib and can save us a lot of work.
1. The Definition Of Swift Closures. Closures are described in the Swift development documentation as functional independent modules that can be passed and referenced in your code. Closures in Swift […]
String interpolation is a way to construct new strings that contain constants, variables, literals, and expressions. Each entry of the string literal you inserted is wrapped in parentheses prefixed by […]
The json library can parse JSON from strings or files. The library parses JSON format string and turns it into a Python dictionary or list. It can also convert Python […]
1. Use “+” Operator To Merge List Directly. >>> list_1 = [‘java’,’python’,’mysql’] >>> >>> list_2 = [100, 99, 101] >>> >>> print(list_1 + list_2) [‘java’, ‘python’, ‘mysql’, 100, 99, 101] […]
This article list some python tricks you may use in python development. It is very useful for you to understand python coding.