Design Patterns - Singleton Patterns (Detailed) See if they are the same as what you understand?
I. overview
Singleton pattern is a relatively simple and common design pattern in design pattern, but it is also a very classic high-frequency interview question. I believe there are still many people hanging here during the interview. This article mainly reviews the singleton pattern, recording its application scenarios, common writing, debugg ...
Added by roots on Tue, 08 Oct 2019 11:03:28 +0300
Buses and People + CodeForces - 160E
Buses and People 3D Processing
Main theme: there are n buses, each bus has s (starting point), f (end point), t (departure time), there are m individuals, each person has l (starting point), R (end point), t (appear time).
For a person, when t <= t (car), s <= l, r <== f, he can get on the ca ...
Added by paddyhaig on Tue, 08 Oct 2019 05:22:54 +0300
[51Nod] 1694 Two Paths (Tree Diameter, Violence)
Bob's brother lives in France. There are n cities in France, and there are n-1 two-way roads connecting these cities. These cities are numbered from 1~n. You can follow these roads from one city to any other city.
Bob's brother worked in the "two way" company and just got to repair a ...
Added by yapyapayap on Tue, 08 Oct 2019 01:49:49 +0300
A Note on Monotone Queue--Sliding Window
Some nonsense:
In memory of hin, a long time ago, the elder gellygoat told us about the monotonous queue that never moved again in his nest.
qbxt's computer compiled once 9s+ can starfish.
f10 is really good.
Topic transfer
Does the data look like it can be clipped by a line segment tree?
As a board question of monotone queue, this qu ...
Added by mchannel on Mon, 07 Oct 2019 23:21:57 +0300
Atomic Integer Source Code Analysis of Dead java Atoms
(mobile phone horizontal screen source code is more convenient)
problem
(1) what is atomic manipulation?
(2) What is the relationship between atomic operation and ACID of database?
(3) How does Atomic Integer implement atomic operations?
(4) what are the shortcomings of AtomicInteger?
brief introduction
Atomic Integer is an atomic class provid ...
Added by splitinfo on Mon, 07 Oct 2019 09:20:52 +0300
Summary of Lftp+Sftp Transmission
Background Introduction:Because of the continuous expansion of backup data, it is necessary to transfer the backup data (about 2T) from the existing network back to the local area for remote storage. But 2T is too big and needs to be compressed. Here we use 3G as a compression package. Here is the compression script
#!/bin/bash
# This script i ...
Added by metrathon on Sun, 06 Oct 2019 13:51:19 +0300
sql server writes archive generic template script to automatically delete data in batches
The blogger has written archive scripts for many projects. For the script development of deleting data, it must be the simplest delete statement at the beginning. Then, because of the large amount of data in some tables and the large number of indexes, it will be found that deleting data is very slow and affects the normal use of the system. Th ...
Added by hori76 on Sun, 06 Oct 2019 13:21:46 +0300
Solution to Luogu P3959 [Treasure]
A less slow pressure???
There's no purple question at all. The data is still so water.
I'm not going to tell you I'm hack ed.
Look at the data size, n < 12, decisive pressure.
Then the starting point needs to be enumerated, and the dp state is set:
f[i][j]= takes I as the starting point to minimize the cost of J status.
Where j is ...
Added by tshafer on Sun, 06 Oct 2019 12:23:59 +0300
Python Learning Diary Mysql Database Part 2
Foreign Key
If there's a table today with a lot of job information on it
We can associate two tables by using foreign keys
Such benefits can save space, for example, you have a long job title today, it is a waste of space to repeat the name of the job in a table; besides, it can also play a restraining role.
Departments, for example, ar ...
Added by one on Sun, 06 Oct 2019 04:45:30 +0300
Post-order traversal of offer-binary search tree with sword finger
Title Description
Enter an integer array to determine whether the array is the result of a post-order traversal of a binary search tree. If yes, output Yes, otherwise output No. Assume that any two numbers of the input array are different from each other.
Knowledge points:
1. Post-order traversal ...
Added by bamse on Sun, 06 Oct 2019 04:10:00 +0300