![](https://img-blog.csdnimg.cn/20201014180756913.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
python
文章平均质量分 84
青停
这个作者很懒,什么都没留下…
展开
-
自动化测试设计模之PO(PageObject)
UI自动化中经常遇到例如也以下场景:需要经常对一个元素进行点击操作,我们会编写多处如下代码driver.find_element_by_id("login-btn").click(),如果开发人员修改了这个元素的id,测试人员需要维护所有对应用例里的代码,用例越多,给测试人员带来的维护工作量就越大,而PO则可以很好的解决这个问题。原创 2022-05-12 18:15:59 · 966 阅读 · 0 评论 -
pip超时问题
https://blog.csdn.net/darkfour/article/details/78191979转载 2020-03-27 10:29:31 · 111 阅读 · 0 评论 -
hackerrank String 7 Designer Door Mat
Mr. Vincent works in a door mat manufacturing company. One day, he designed a new door mat with the following specifications:Mat size must beX. (is an odd natural number, andistimes.) The de...原创 2020-02-07 13:30:46 · 104 阅读 · 0 评论 -
List 截取倒序
python list截取倒序,[]里第一个 : 左右为数组截取第索引位置(左边为大的索引位置,右边为小的索引位置,反过来),左边如果为空,默认为最后一个索引位置,右边为空,默认为索引0;后面 :-1 固定a = [1, 3, 4, 2, 'a', 'd']print a[3:1:-1]print a[::-1]print a[3::-1]print a[:4:-1]print ...原创 2020-02-07 12:09:45 · 409 阅读 · 0 评论 -
hackerrank String 6 Text Wrap
CheckTutorialtab to know how to to solve.You are given a stringand width.Your task is to wrap the string into a paragraph of width.Input FormatThe first line contains a string,.The seco...原创 2020-02-06 16:41:59 · 130 阅读 · 0 评论 -
hackerrank String 5 Text Alignment
TaskYou are given a partial code that is used for generating theHackerRank Logoof variablethickness.Your task is to replace the blank (______) withrjust, ljustorcenter.Input FormatA singl...原创 2020-02-06 15:45:38 · 244 阅读 · 0 评论 -
hackerrank String 4 String Validators
TaskYou are given a string.Your task is to find out if the stringcontains:alphanumeric characters, alphabetical characters, digits, lowercase and uppercase characters.Input FormatA singl...原创 2020-02-05 18:28:31 · 142 阅读 · 0 评论 -
hackerrank String 3 Find a string
In this challenge, the user enters a string and a substring. You have to print the number of times that the substring occurs in the given string. String traversal will take place from left to right, n...原创 2020-02-05 16:52:47 · 185 阅读 · 0 评论 -
hackerrank String 2 Split and Join
In Python, a string can be split on a delimiter.Example:>>> a = "this is a string">>> a = a.split(" ") # a is converted to a list of strings. >>> print a['this', 'is...原创 2020-02-05 15:14:49 · 145 阅读 · 0 评论 -
hackerrank String 1 swap cases
You are given a string and your task is toswap cases. In other words, convert all lowercase letters to uppercase letters and vice versa.For Example:Www.HackerRank.com → wWW.hACKERrANK.COMPython...原创 2020-02-05 14:46:56 · 160 阅读 · 0 评论 -
Python hash() 函数 -- 笔记
hash()用于获取取一个对象(字符串或者数值等)的哈希值。释义:通过一定的哈希算法(典型的有MD5,SHA-1等),将一段较长的数据映射为较短小的数据,这段小数据就是大数据的哈希值。他有这样一个特点,他是唯一的,一旦大数据发生了变化,哪怕是一个微小的变化,他的哈希值也会发生变化。hash() 函数的用途hash() 函数的对象字符不管有多长,返回的 hash 值都是固定长度的,也用...转载 2020-02-05 11:14:45 · 241 阅读 · 0 评论 -
hackerrank -python --List 2
You have a record ofstudents. Each record contains the student's name, and their percent marks in Maths, Physics and Chemistry. The marks can be floating values. The user enters some integerfollow...原创 2020-02-04 11:35:02 · 222 阅读 · 0 评论 -
hackerrank -python --List 3
Given the names and grades for each student in a Physics class ofstudents, store them in a nested list and print the name(s) of any student(s) having the second lowest grade.Note:If there are mul...原创 2020-02-03 17:27:13 · 232 阅读 · 0 评论 -
hackerrank -python --List 1
Consider a list (list = []). You can perform the following commands:insert i e: Insert integerat position. print: Print the list. remove e: Delete the first occurrence of integer. append e: I...原创 2020-02-03 14:47:38 · 251 阅读 · 0 评论 -
hackerrank -python --List 4
Given the participants' score sheet for your University Sports Day, you are required to find the runner-up score. You are givenscores. Store them in a list and find the score of the runner-up.Inpu...原创 2020-02-02 17:48:47 · 237 阅读 · 0 评论 -
查看selenium版本
此方法在pycharm里执行1. 打开命令行,输入pythonF:\autotest\pycharm\test1>pythonPython 3.7.4 (tags/v3.7.4:e09359112e, Jul 8 2019, 19:29:22) [MSC v.1916 32 bit (Intel)] on win32Type "help", "copyright", "cred...原创 2019-10-21 14:59:54 · 1722 阅读 · 0 评论 -
pycharm无法打开ini文件--手动添加Ini4Idea
1. 查看pycharm版本号,help --> About。2.进入官网:http://plugins.jetbrains.com,选中pycharm及相关版本,搜索ini,切到版本,下载与pycharm版本最近的插件3. 在pycharm,file-->setting --> Plugins里选择install Plugin from disk ,选择下载到...原创 2019-08-20 15:43:17 · 1876 阅读 · 0 评论 -
uuid 低级错误 'module' object has no attribute 'uuid1'
执行如下文件,报错 'module' object has no attribute 'uuid1',然后到stackoverflow啃英语,嗯,最后呢,原来你是因为我把文件名命名为 uuid.py,低级错误。。记录下谨记。#encoding=utf-8import uuid###### 功能描述:###### 生成一个唯一的字符串print uuid.uuid1()result ...原创 2019-04-11 16:56:08 · 3954 阅读 · 8 评论