Before writing Python, add the jmter pressure test to add the load machine:
1. First need to start jmter-server, the service in the JMeter bin directory
2. Next need to change the jmeter.properties configuration file, change the file is also in the JMeter Bin directory, and then open with Notepad, search remote host, add the other IP
3. Finally restart the Jmter, remote boot can
Python Basics:
Python is an interpreted language
Python can be used for data mining (crawlers), data analysis, automated operations, automated testing, backend service interfaces, AI, AI, embedded, web development
First, the basic operator
equals: = =
Not equal to:! =
Greater than: >
Less than:<
Greater than or equal to: >=
Less than equals: <=
second, define variables:name = ' YBQ ' #定义变量 strings quoted are best seen when they are definedname = ' Little black ' #定义成中文也可以, better not, too lowname = "Let's Go" #字符串里有单引号了就用双引号 with double quotes and single quotestxz = ' let ' go, ' haha ' #字符串里有单引号和双引号, use 3 quotation marks (3 single quotes)"is also a multiline commentthird, input inputs use:name = input (' Please enter your name ')print (' Your name is ', name ')Python3 Default Character set is unicode,2 default is ASCII, use 2 words need to precede with #coding=utf-8
Four, character formatting output:
Username = input (' name: ')Time =' 2011 'Print (username+' welcom ') # (two strings via + stitching) Print'%s,hwelcom '%username)Print'%s,hwelcom,s% '% (username,time)) #这么写效率高 S is string,d is an integer int,f is a decimal float Print' {},hwelcom,{} '. Format (username,time)) #这么写效率最高Print' {username},hwelcom,{time} '. Format (username=username,time=time))v. Circulation:For loop while loop whilethere must be a counter in the while loopcontinue end this cycle and proceed to the next cycleBreak Direct End Loop
Count =0
While count <:print (' good haha ')count = Count +1#count +=1 BreakElse: #正常循环结束后执行elseprint (' Done ') #正常循环结束后输出的For LoopFor I in range (Ten): Print' OK ', i)
Automated Day2---python basics