Defined:
#define EXAMPLE (x) printf ("x =%d", x)
i = 10; j = 11;EXAMPLE (i)EXAMPLE (j)i = 20; j = 21;EXAMPLE (i)EXAMPLE (j)
Output:
x = 10x = 11x = 20x = 21
This output is not the effect we want.Modifies the use of printf in a macro definition.
#define EXAMPLE (x) printf (#x "=%d", x)
Output:
i = 10j = 11i = 20j = 21
# awk ' Condition 1{action 1} Condition 2{action 2} ... ' File namecondition (Pattern):Generally use relational expressions as conditions x > 10 to determine if a variable x is greater than 10x>=10 greater than or equal to xactions (Action):Formatting output Flow control statementstext message: Vim score.txt
1234
ID Name PHP Linux MySQL Average1 Liming 82 95 86 87.662 Sc 74 96 87 85.663 Gao 99 83 93 91.66
1. Output scor
commands can be used with the number, such as delete 10 characters 10x, after the current position after inserting 3! , 3a! W moves forward one word (the cursor stops at the beginning of the word), and if it is at the end of the line, go to the start of the next line. This command is fast and can replace the L command.b Move backward one word 2b move backwards 2 wordsE, with W, except that the cursor stops at the tail of the word.GE, with B, the curs
, Evaluation-3 5System.out.println ( -3 5);//-38, do not introduce a 3rd value or variable, Exchange 2 data valuesint x = 10;int y = 5;x = x ^ y; 10 ^ 5y = x ^ y; Ten ^ 5 ^ 5 y = 10x = x ^ y; Ten ^ 5 ^ ten x = 5System.out.println ("x =" + x + ", y =" + y ");9, the most efficient calculation of 2 of the 3-time SquareSystem.out.println (2Shift a number to the left N-bit, which is equivalent to multiplying by 2 of the N-squar
. ' is a space that fills a space on the left side of a positive number to align with a negative number. 0 means using 0 padding.Width indicates display widthsPrecision indicates the precision after the decimal pointLike what:Print ("%+10x") print ("%04d"% 5) print ("%6.3f"% 2.3)The width above, precision is two integers. We can use * to dynamically substitute these two quantities. Like what:Print ("%.*f"% (4, 1.2))Python actually replaces * with 4来.
Label:BULK INSERT http://blog.csdn.net/xiaoxian8023/article/details/20155429 Mysql JDBC Batch data, need to add rewritebatchedstatements=true to JDBC connection. The default JDBC is not to turn on batch processing. Example: Jdbc:mysql://10.250.4.98:3306/dbname rewritebatchedstatements=true Java Updatebatchsample: Official Website Forums 39,260053,263456#msg-263456 MySQL itself have no real "batch" API for prepared statements.If You add the configuration property "Rewritebatchedstatements=true"
of variable itself is called Dynamic language, which corresponds to static language. Static languages must specify the variable type when defining the variable, and if the type does not match, an error is given. For example, Java is a static language, and assignment statements are as follows (//for comments):int a = 123; // a是整数类型变量a = "ABC"; // 错误:不能把字符串赋给整型变量This is why dynamic languages are more flexible than static languages.Do not equate an equal sign of an assignment statement with a math
type of variable itself is called Dynamic language, which corresponds to static language. Static languages must specify the variable type when defining the variable, and if the type does not match, an error is given. For example, Java is a static language, and assignment statements are as follows (//for comments):int a = 123; // a是整数类型变量a = "ABC"; // 错误:不能把字符串赋给整型变量This is why dynamic languages are more flexible than static languages.Do not equate an equal sign of an assignment statement with a
complete.: Set Wrapscan re-search, when searching to the head or end of the file, return to continue the search, by default open.Replace commandThe RA replaces the current character with a, when the period character is the character of the cursor.s/old/new/replace new with old, replacing the first match of the current rows/old/new/g replace new with old, replacing all occurrences of the current row%s/old/new/replace new with old, replacing the first match of all rows%s/old/new/g replace new wit
One, vim repeat command 1. Repeat the last commandIn normal mode . (decimal point) means the last command operation is repeatedCopy test files to a local directory$ cp /etc/protocols .Open a file for editing$ vim protocolsNormal mode input x , delete the first character, the input . (decimal point) will be deleted again a character, in addition to also can be repeated dd delete operation2. Execute commands of the same number of timesEnter Normal mode input N , n indicates the number of repetitio
access all domain names.SummaryThe combination of HTTP/2 and TLS can improve the performance of your site and make users feel that your site is safe. Whether you are the first to achieve HTTP/2 in your own application, or to catch up with your competitors, you can quickly and well achieve the support of HTTP/2.Hopefully this article will allow you to get the most out of your HTTP/2 performance with minimal effort, and from then on you can focus on writing faster, more efficient, more secure app
solutions. For example, consider the following linear equation group:Listing 1. Linear equation System sample
10x + 5y-7z + 1 = 0
17x + 5y-10z + 3 = 0
5x-4y + 3z-6 = 0
It's a pretty nice simple expression of several relationships between objects (x, y, and Z). In real life you may find these answers in different ways, but actually it's annoying and error-prone to "solve X" with pen and paper. From a debugging standpoint, it might be wo
" mechanisms in C + +, but they also force us to include the implementation in the header file, which is a great contribution to increasing the content of the header file and slowing the compilation speed. Before using, weigh it.
Ii. Comprehensive Skills
Precompiled Header file (PCH)
Put some common but infrequently modified header files in the precompiled header file. This way, at least in a single project you don't need to load and parse the same header file over and over again in each compila
mode
CTRL+G Press the 10x button in scientific mode
F5 Select Hex in programmer mode
F6 Select Dec in programmer mode
F7 Select Oct in programmer mode
F8 Select Bin in programmer mode
F12 Select Qword in programmer mode
F2 Select Dword in programmer mode
F3 Select Word in programmer mode
F4 Select Byte in programmer mode
K Press RoR button in programmer mode
J Press RoL button in programmer mode
% in Programmer mode Press Mod button
(Pre
the left 5 characters, in vim, many commands can be used with digital, such as the deletion of 10 characters 10x, in the current position after inserting 3. , 3a.
W moves one word forward (the cursor stops at the word header), and if it is at the end of the line, go to the beginning of the next line. This command is quick and can replace the L command.
b Move one word back 2b move 2 words back
E, same w, just the cursor stops at the end of the word
Recently sorted out some in-use, feel good open source gadgets, some only for MacOS, but most cross-platform.
Homebrew
homebrew-the missing packages manager for MacOS: Https://brew.sh,Mac is a very good package management tool, many common installations can be installed through the brew install The app or brew cask install app is installed directly, similar to Apt-get.
Oh My Zsh
If you often use the command line, that + oh-my-zsh: Https://github.com/robbyrussell/oh-my-zsh is definitely a must-
delay at 0.5ms,b bolt delay in 0.1ms,d bolt delay in 1.0ms,e Bolt delay at 0.2ms, so can be considered performance: b=2e=5a=5c=10d, so we improve the efficiency of the entire topology can adjust the degree of parallelism of each bolt, we set the degree of parallelism of B is X, can be derived X+2x+5x*2+10x=all executor , if there is a blockage in a bolt, we can increase some degree of parallelism, the environment of three machines, the maximum degree
Recently installed on the VirtualBox CentOS, suddenly found the CPU fan turned, a check, the original VirtualBox on the CentOS almost in 100% use VirtualBox assigned to its CPU core. On the internet to find a half-day, finally found a method, namely: Modify the/etc/grub.conf file, in the kernel row after adding the parameter "divider=10", after testing, sure enough the CPU is normal.
Explanation of divider=10:
For RHEL 5.4 and CentOS 5.4 and later, divider=10 are a supported kernel configura
Created by Ken Stevens. Last edited by Steve Shaw, 1 ago.
For your project we needed to encrypt a number of columns in the database for security purposes and tried out a tool called Jasypt and were able to meet we encryption requirements in under a day. Here is the changes we made to get it to work. Increase size of columns to being is encrypted in database. (3x was wasn't large enough, 10x was large enough). Change the type of non-varchar columns to
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.