题解列表

筛选

[编程入门]二维数组的转置 python初学

摘要:解题思路:                对于一个数组, 输出时 只需将 行变为列,列变为行即可注意事项:                python 二维数组的输入参考代码:a&nb

1219: 数列排序

摘要:```python n = int(input()) for i in range(n): st1, st2 = '', '' lis = list(map(str, inpu……

蓝桥杯算法训练VIP-矩阵加法 (python)

摘要:解题思路:这个网站对写python的太不友好了,都没有答案,还得自己写,哭了哭了注意事项:参考代码:N,M = map(int,input().split())l = []l2 = []for i i……

明明的随机数-python简单解决

摘要:1、用map()高阶函数解决输入问题; 2、使用集合特性去重; 3、列表函数直接排序; ```python n = int(input()) l = set(map(int, input()……

数组的距离

摘要: ```python from math import fabs a, b = input().split() l1 = list(map(int,input().split())) l……

1162: 密码(判断密码是否合规)

摘要:```python #将四种不同类型的字符存在四个列表中,长度符合要求的情况下判断密码的字符种类是否有3种及以上。 #(易错点,读入的密码是以字符形式存储的,因此数字0-9的这类对应的列表中也应该……

[出圈]幸存者问题

摘要:解题思路:注意事项:参考代码:while True:    try:        a, b = map(int, input().strip().split())        l = [i for……

素数问题python

摘要:解题思路:注意事项:参考代码:n = int(input())if n == 1:    print(0)else:    flag = 1    for j in range(2,n//2+1): ……