Signed-off-by: 10_2 <sairate@sina.cn>

This commit is contained in:
10_2 2024-07-16 09:03:37 +08:00
commit 959e42ab22
15 changed files with 164 additions and 0 deletions

3
.idea/.gitignore vendored Normal file
View File

@ -0,0 +1,3 @@
# 默认忽略的文件
/shelf/
/workspace.xml

1
.idea/.name Normal file
View File

@ -0,0 +1 @@
2024.7.5.2.py

View File

@ -0,0 +1,6 @@
<component name="InspectionProjectProfileManager">
<settings>
<option name="USE_PROJECT_PROFILE" value="false" />
<version value="1.0" />
</settings>
</component>

4
.idea/misc.xml Normal file
View File

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.10 (杜奕扬)" project-jdk-type="Python SDK" />
</project>

8
.idea/modules.xml Normal file
View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/杜奕扬.iml" filepath="$PROJECT_DIR$/.idea/杜奕扬.iml" />
</modules>
</component>
</project>

10
.idea/杜奕扬.iml Normal file
View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="PYTHON_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$">
<excludeFolder url="file://$MODULE_DIR$/venv" />
</content>
<orderEntry type="jdk" jdkName="Python 3.10 (杜奕扬)" jdkType="Python SDK" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

25
2024.6.29.py Normal file
View File

@ -0,0 +1,25 @@
b='ABCCBACBAC'
n=int(input('请输入人数'))
list=[]
for i in range(0,n):
list.append(input())
score=[0]
correct_daan=[""]
count=1
for j in list:
score.append(0)
correct_daan.append("")
daan=j
for i in range(0, 10):
if daan[i] == b[i]:
correct_daan[count] += b[i]
score[count] += 10
else:
correct_daan[count] += 'X'
count+=1
for i in range(1,len(score)):
print("{}号学员,{}分数".format(i,score[i]),correct_daan[i])

9
2024.7.1.1.py Normal file
View File

@ -0,0 +1,9 @@
a=int(input(''))
b=65
for i in range(1,a+1):
for j in range(1,i+1):
print(chr(b),end='')
b+=1
if b>90:
b=65
print('')

6
2024.7.1.py Normal file
View File

@ -0,0 +1,6 @@
for i in range(1 , 10):
for j in range(1,i +1):
print('{}X{}={}'.format(i , j , i*j),end=' ')
print(' ')

0
2024.7.16.py Normal file
View File

16
2024.7.3.py Normal file
View File

@ -0,0 +1,16 @@
import turtle
t=turtle.Turtle()
import random
t.speed(0)
t.pensize(10)
for i in range(180):
for j in range(8):
r=random.random()
g = random.random()
b = random.random()
t.pencolor(r,0.5,1)
t.forward(120)
t.right(360/8)
t.right(2)
turtle.done()

14
2024.7.5.1.py Normal file
View File

@ -0,0 +1,14 @@
import turtle
import random
t=turtle.Turtle()
t.speed(0)
n=0
m=0
l=0
for i in range(500):
t.forward(i)
t.left(91)
r = random.random()
g = random.random()
b = random.random()
t.pencolor(1, 1, b)

5
2024.7.5.2.py Normal file
View File

@ -0,0 +1,5 @@
n=int(input(''))
for i in range(n-1,1,-1):
if n%i==0:
print(i)
break

41
2024.7.5.py Normal file
View File

@ -0,0 +1,41 @@
import turtle
import random
t=turtle.Turtle()
t.speed(0)
t.pencolor('yellow')
t.fillcolor(1,165/255,0)
t.begin_fill()
t=turtle.Turtle()
t.speed(0)
n=0
m=0
l=0
for i in range(500):
t.forward(i)
t.left(91)
r = random.random()
g = random.random()
b = random.random()
t.pencolor('blue')
t.goto(0,0)
t.pencolor('yellow')
t.fillcolor(1,165/255,0)
t.begin_fill()
for a in range(10):
t.left(35)
for a in range(5):
t.forward(100)
t.left(72)
t.forward(100)
t.right(144)
t.end_fill()
t.pencolor('red')
t.speed(0)
t.fillcolor('yellow')
t.begin_fill()
for j in range(12):
for i in range(36):
t.forward(300)
t.left(170)
t.left(30)
t.end_fill()

16
main.py Normal file
View File

@ -0,0 +1,16 @@
# 这是一个示例 Python 脚本。
# 按 Shift+F10 执行或将其替换为您的代码。
# 按 双击 Shift 在所有地方搜索类、文件、工具窗口、操作和设置。
def print_hi(name):
# 在下面的代码行中使用断点来调试脚本。
print(f'Hi, {name}') # 按 Ctrl+F8 切换断点。
# 按间距中的绿色按钮以运行脚本。
if __name__ == '__main__':
print_hi('PyCharm')
# 访问 https://www.jetbrains.com/help/pycharm/ 获取 PyCharm 帮助