| 
 
TA的每日心情|  | 开心 2023-9-4 15:59
 | 
|---|
 签到天数: 445 天 [LV.9]以坛为家II | 
 
| 本帖最后由 wolf0000 于 2022-5-23 12:33 编辑 
 复制代码from selenium import webdriver
from selenium.webdriver.common.by import By
options = webdriver.ChromeOptions()
options.add_argument("--window-size=1920,1080")
driver = webdriver.Chrome(options=options) # 获取驱动
driver.get("http://www.baidu.com") # 打开百度链接
driver.find_element(By.ID,"kw").send_keys("自动化测试")
driver.find_element(By.ID,"su").click()
driver.close()
'''
Palindrome detection
'''
str = input("Please enter a string:")
str1 = (str[::-1])
print(str1)
if str == str1 and len(str) != 0:
    if len(str) % 2  == 0:
        print("palindrome plus even number")
    elif len(str) % 2  == 1:
        print("palindrome plus odd number")
else:
    print("not a palindrome")
 
 
 
 | 
 
x本帖子中包含更多资源您需要 登录 才可以下载或查看,没有帐号?注册  |