首页
题库
面试
求职
学习
竞赛
More+
所有博客
搜索面经/职位/试题/公司
搜索
我要招人
去企业版
登录 / 注册
lzher0
门头沟学院
2020届
算法工程师
关注
私信
加入黑名单
举报TA
首页
刷题
圈子
项目
笔记
基本资料
真题试卷
在线编程
心理测试
回答的问题(62)
牛牛的闹钟
0
n = int(input()) res = [] for i in range(n): s = input() h, m = map(int, s.split()) res.append((h*60+m, s)) time = int(input()) cls_h, cls...
发表于 2019-08-14 07:59:58
推倒吧骨牌
0
s = input() ans = list(s) flag = [(i,x) for i, x in enumerate(s) if x != '.'] flag = [(-1,"L")] + flag + [(len(s),"R")] for i in r...
发表于 2019-08-13 08:51:16
字符串长度最大乘积
0
s = eval(input()) res, cnt = 0, 0 for i in range(len(s)): for j in range(i+1,len(s)): if len(set(s[i]))+len(set(s[j])) == len(set(s[i]+s[j...
发表于 2019-08-12 07:59:02
二分图判定
0
n,m = map(int, input().split()) dic = {} flag = 'Yes' k = m-1 if n<m else m #避免第一个样例的情况 for i in range(k): u, v = map(int, input().split()) ...
发表于 2019-08-09 11:07:33
查找无重复最长子串
0
s = list(input()) l = [] res,cnt = 0,0 for i in range(len(s)): if s[i] not in l: l.append(s[i]) cnt += 1 res = max(cnt, r...
发表于 2019-08-09 10:19:21
找出单向链表中的一个节点,该节点到尾指针的距离为K
5
class Node: def __init__(self,x): self.val = x self.next = None head = Node(0) temp = head for i in range(1,8): node = Node(i)...
发表于 2019-08-09 10:05:37
X游戏
0
n = int(input()) res = 0 for i in range(1,n+1): s = str(i) if '3' not in s and '4' not in s and '7' not in s: if '2' in s or '5' in s ...
发表于 2019-08-09 09:52:11
爬楼梯2
0
def helper(n): dp = list(0 for _ in range(n+1)) dp[1] = 1 dp[2] = 1 dp[3] = 2 for i in range(4,n+1): dp[i] = dp[i-1]+dp[i-...
发表于 2019-08-09 08:27:58
商品交易
2
n = int(input()) num = list(map(int, input().split())) deal = 0 profit = 0 cnt = 0 for i in range(1,n): if num[i] > num[i-1]: profit +=...
发表于 2019-08-07 09:03:02
学数学
0
def isprime(n): for i in range(2, n): if n%i == 0: return False return True n = int(input()) res = 0 for i in range(2,n//...
发表于 2019-08-01 22:11:36
首页
上一页
1
2
3
4
5
6
7
下一页
末页
扫描二维码,关注牛客网
意见反馈
下载牛客APP,随时随地刷题