[C + +] 38 traps of logical operators

Rule Primitive semantics of logical operators Operators have only two values (true and false) The logic expression can determine the final value without complete calculation (short circuit rule) The final result can only be true or false Programming experiments: logical expressions #include <iostream> #include <string> using na ...

Posted by Silverlime on Wed, 04 Dec 2019 01:25:25 -0800

bzoj1497 maximum profit (maximum weighted closed subgraph)

Title Link thinking For each transit station, connect a weight to \ (T \) to the side of the cost of building this transit station. Cutting this edge means that the transfer station will be built. For each person, connect an edge with a weight of \ (INF \) to his two transfer stations. Then connect an edge from \ (S \) to this person whose weig ...

Posted by aleczapka on Wed, 04 Dec 2019 01:17:12 -0800

Parallel Pattern Library(PPL) learning notes

About what PPL is, you can search the keyword MSDN PPL for details. Here's a place that has been bothering me for a long time -- the handling of exceptions thrown in the task chain. It can be used as a reference for other coders, and it can make a record for myself to avoid forgetting in the future. Successful attempt of value based continuatio ...

Posted by itshim on Tue, 03 Dec 2019 22:33:41 -0800

MFC develops a simple synchronous time application

Looking at the structure of a garbage program, mmp is a real pit. It took me a little time to finish it. Just record it directly. This is a simple application of windows, but it's a little complicated. We need to build an app Wizard program based on mfc (written by memory, I don't know if there are any mistakes in the words). Then we can add th ...

Posted by DataRater on Tue, 03 Dec 2019 20:36:20 -0800

The second day after leetcode

Title Description Two non empty linked lists are given to represent two non negative integers. Their respective digits are stored in reverse order, and each node can only store one digit. If we add the two numbers together, we will return a new linked list to represent their sum. You can assume that neither of these numbers starts with 0 exce ...

Posted by beboo002 on Tue, 03 Dec 2019 03:02:43 -0800

LOJ Chen 6491. Zrq inversion (dubius inversion)

meaning of the title Title Link Sol Inversion routine? But the last step is pretty good. Routine enumeration (d \), simplification can get \[\sum_{T = 1}^m (\frac{M}{T})^n \sum_{d \ | T} d \mu(\frac{T}{d})\] The following is obviously in the form of Dirichlet convolution, but here \ (n \leqslant 10^{11} \) obviously can't be directly linear scr ...

Posted by dougal85 on Tue, 03 Dec 2019 00:38:41 -0800

Deep in Debian Linux install ffmpeg

Installing CMake and CCMake sudo apt install cmake sudo apt install cmake-curses-gui Install X265 development library sudo apt-get install libx265-dev Install Yasm Download address: http://www.tortall.net/projects/yasm/releases/ tar -xvf yasm-1.3.0.tar.gz cd yasm-1.3.0/ ./configure make && make install Install OpenCoreAMR Download addr ...

Posted by dlgilbert on Mon, 02 Dec 2019 14:23:04 -0800

[luogu3709] [my string question]

Title Link meaning of the title It's enough to do two such questions a day to describe such a fairy. Really exercise Chinese ability. The meaning of a question is to give you a sequence and then ask for an interval at a time. Make it possible to take the data from this interval in strict ascending order. If the current acquisition number is le ...

Posted by yankeefan238 on Mon, 02 Dec 2019 11:09:24 -0800

The queue with the maximum cache limit realized by the condition variable of c++11

Queues with the maximum length limit through the condition ﹣ variable: #include <condition_variable> #include <queue> #include <chrono> #include <iostream> /* * There is a maximum number of queues limit */ // parameter T Need to be able to copy,And the copy doesn't have side effects template <typename T> clas ...

Posted by webbnino on Mon, 02 Dec 2019 10:06:41 -0800

How can C output an N-order matrix with increasing return type (primary algorithm)

First of all, when it comes to the output matrix, no matter what level of people will think it is the most convenient to use arrays, so what is explained here is the implementation of using multidimensional arrays. The first is the variable definition required by the algorithm int i,j,n,sum; printf("Please enter the column length of the matrix ...

Posted by Phire on Mon, 02 Dec 2019 08:45:32 -0800