Common methods: Lists, tuples, dictionaries and strings can be used together.
Python built-in functions
Listing of built-in functions
Calculate the number of elements in the container
del has two methods
Returns the maximum value of the element in the container
Posted by flashbot on Wed, 08 May 2019 11:30:03 +0200
Function Compute is an event-driven service. Through function computing, users do not need to manage the operation of servers, but only write code and upload it. Function computing prepares computing resources and runs user code in a flexible and scalable manner, while users only need to pay for the resources consumed by running the act ...
Posted by blui on Wed, 08 May 2019 01:50:03 +0200
Article firstCreative Patterns: Factory Approach
Name: Factory Method
English name: Factory method Pattern
Values: Expansion is my monopoly
Define an interface for creating an object, but let subclasses decide which class to instantiate. Factory Methods lets a class defer instantiation to subclasses. ...
Posted by FFEMTcJ on Tue, 07 May 2019 18:45:04 +0200
Array method collation
all(), any(), none() and one() Testing whether all or part of the elements in an array satisfy a given condition. Conditions can be determined in a block of statements or parameters.
append() Equivalent to push()
bsearch() Dichotomy Finding Elements
bsearch_index() Dichotomy Finds Elements and Returns ...
Posted by ricoche on Tue, 07 May 2019 13:35:03 +0200
Class and instance
Classes are abstract templates, and instances are concrete "objects" created according to classes.
Class: A collection of objects that describe the same properties and methods. It defines the properties and methods common to each object in the set. Objects are instances of ...
Posted by kevgais on Tue, 07 May 2019 10:40:04 +0200
We always use redis of Aliyun. We are not a high concurrent application. We mainly use redis as distributed locks and a small amount of caches. It hardly needs maintenance. Yesterday afternoon, we suddenly received an alarm email. On-line redis memory is used 100% and instantaneous nerve tension sensation is confirmed by console.This is a ...
Posted by jim_de_bo on Mon, 06 May 2019 15:00:04 +0200
Django Blog Series (I)
After learning Python for so long, I finally got to the Django framework. This can be said to be python's most famous web framework, so from today on, we will start to install the Django framework to use step-by-step learning. This series of blogs will not be as watery as the front end (flag), hoping to become a h ...
Posted by richclever on Mon, 06 May 2019 13:05:03 +0200
Python A standard module library is attached and described in a separate document Python library reference (hereinafter referred to as "library reference"). Some modules are built into interpreters; they provide access to operations that are not part of the language core but are still built in to improve efficiency or provide access t ...
Posted by tpl41803 on Mon, 06 May 2019 02:40:02 +0200
npm is to Node.js, just as pip is to Python, gem is to Ruby, and pear is to PHP.npm is the official package management tool provided by Node.js. It has become the standard platform for Node.js package publishing, dissemination and dependency control. npm provides command-line tools to make it easy to download, install, upgrade, ...
Posted by SBro on Sun, 05 May 2019 23:40:02 +0200
Today we are going to learn collision detection. Most games need to do collision detection because you need to know whether the ball collided, whether the bullet hit the target, whether the protagonist stepped on the shit.
How should that be achieved?
To put it bluntly, the principle is simple, that is, to detect whether there i ...
Posted by TreeNode on Sun, 05 May 2019 15:48:04 +0200