牛客681521211号
牛客681521211号
全部文章
题解
归档
标签
去牛客网
登录
/
注册
牛客681521211号的博客
全部文章
/ 题解
(共28篇)
题解 | #百钱买百鸡问题#
while True: try: n=int(input()) for num in range(4): a=4*num b=25-7*num c=75+3*num ...
Python3
2021-10-16
0
370
题解 | #配置文件恢复#
while True: try: n=input().strip().split() key=["reset","reset board","board add","board delete","reboot backplane","backplane abo...
Python3
2021-10-16
1
527
题解 | #配置文件恢复#
while True: try: n=input().strip().split() key=["reset","reset board","board add","board delete","reboot backplane","backplane abo...
Python3
2021-10-16
0
374
题解 | #查找输入整数二进制中1的个数#
while True: try: num=bin(int(input())) a=num.count("1") print(a) except: break
Python3
2021-10-16
0
381
题解 | #放苹果#
def f(m,n): if n < 0 or m < 0: return 0 elif n == 1: return 1 else: return f(m,n-1)+f(m-n,n) while True: ...
Python3
2021-10-15
0
437
题解 | #完全数计算#
while True: try: b=0 n=int(input()) for i in range(1,n+1): a=0 for j in range(1,i): ...
Python3
2021-10-15
0
384
题解 | #密码验证合格程序#
def check(s): x=[] a,b,ct,d=0,0,0,0 if len(s) <= 8: return 0 else: for i in s: if ord("a") <= ord(i)...
Python3
2021-10-15
0
454
题解 | #提取不重复的整数#
a=input() b="" for i in range(1,len(a)+1): if a[-i] not in b: b+=a[-i] else: continue if b[0] == 0: print(b[1:]) else: ...
Python3
2021-10-15
0
430
题解 | #统计每个月兔子的总数#
def f(n): if n <= 2: return 1 else: return f(n-1)+f(n-2) while True: try: n=int(input()) print(f(n)) ...
Python3
2021-10-15
12
654
题解 | #输入整型数组和排序标识,对其元素按照升序或降序进行排序#
n=int(input()) d=list(map(int,input().split())) x=int(input()) if x == 0: for i in sorted(d): print(i,end=" ") else: d=sorted(d,revers...
Python3
2021-10-15
13
1045
首页
上一页
1
2
3
下一页
末页