Flask resolution: Local, LocalStak, LocalProxy
What is Local?
Whether you are exposed to threading.Local or werkzeug.Local, they represent a variable - each thread's own global variable.
Global variables, usually on the process heap. All threads of a process can access the same global variable, because they share the address space of the process, so each thread can access it, which al ...
Posted by theresandy on Sat, 02 Nov 2019 06:18:05 -0700
[the road to full stack] top ten new features of JAVA basic course 11 JDK8 (20190706v1.2)
Welcome to JAVA basic course
Blog address: https://blog.csdn.net/houjiyu...This series of articles will mainly focus on some basic knowledge points of JAVA, which are summarized in ordinary times. No matter you are new to JAVA development rookie or senior people in the industry, you hope to bring some help to your peers. If you have any questi ...
Posted by jf3000 on Sat, 02 Nov 2019 05:35:39 -0700
LeetCode 1071. Maximum common factor of string (python)
Title Link
Title Description:
For strings S and T, only if S = T +... +Only when t (t is connected to itself once or more), can we determine that "t can eliminate s".
Returns the string x, which requires that x can divide str1 and X can divide str2.
Example 1:
Input: str1 = "ABCABC", ...
Posted by trev on Tue, 29 Oct 2019 13:56:12 -0700
Python(day.5 function and Lambda expression)
function
To create a function, the keyword del is used, followed by a colon and its executor.
>>>del MyFirstFunction():
print('hello')
print('world')
print('!')
>>>MyFirstFunction()
hello
world
!
Parameters of function
When calling a function, the parameter position should b ...
Posted by designxperts on Sat, 26 Oct 2019 08:08:38 -0700
C. learning notes [IX] - one of the entrustments
9.1 declaration and assignment of delegation
Delegate is a type of storage function reference.
The definition of a delegate specifies a return type and a list of parameters that tell the compiler which types of methods the delegate can point to.
After defining a delegate, you can create an instanc ...
Posted by scotchegg78 on Sat, 26 Oct 2019 04:39:26 -0700
Task04: string and sequence (1day)
We are going to use 17 days to divide the deliberate practice of Python foundation into the following tasks:
Task01: variables, operators and data types (1day)
Task02: condition and cycle (1day)
Task03: list and tuple (2day)
Task04: string and sequence (1day)
Task05: functions and Lambda expressions (2 ...
Posted by Dani34 on Thu, 24 Oct 2019 07:24:52 -0700
Learn java 8 together -- method reference
Let's learn java 8 (1) - there is a simple example of functional programming in functional programming:
import java.util.function.Consumer;
class Person {
public static void sayHello(String name) {
System.out.println("hello " + name);
}
}
public class TestPerson {
public static void main(String[] args) {
work(Person::sayHe ...
Posted by blakey on Mon, 21 Oct 2019 22:04:30 -0700
GUI - Notepad project
Notepad project development
""" Developing Notepad software """
# -*- coding: utf-8 -*-
from tkinter import *
from tkinter.colorchooser import *
from tkinter.filedialog import *
from tkinter.messagebox import *
class Application(Frame):
def __init__(self,master=None):
super().__init__(mas ...
Posted by phphunger on Sat, 19 Oct 2019 10:35:09 -0700
Learning record (day02-Es6 template string, deconstruction assignment, arrow function, data structure, for..of traversal, rest parameter, extended operator))
Day02(Es6 template string, deconstruction assignment, arrow function, data structure, for..of traversal, rest parameter, extension operator)
[TOC]
1.1.1 template string
Template string to simplify string patching
//statement
var str = ``;
//Embedded variables
var str = `${variable}`;
// username + "___" + password
// `${username} ---- ...
Posted by HaZaRd420 on Wed, 16 Oct 2019 06:50:44 -0700
Java 8 new features learning notes
Java 8 new features learning notes
1 main content
Lambda expression
Functional interface
Method reference and constructor reference
Stream API
Default method and static method in interface
New time date API
Other new features
2 succinct
Faster to modify the algorithm of the underlying Hash list, HashMap, HashSet (add list from the previous a ...
Posted by joshblue on Wed, 16 Oct 2019 04:44:42 -0700