题解 | #记票统计#

记票统计

http://www.nowcoder.com/practice/3350d379a5d44054b219de7af6708894

i1 = int(input())
lt1 = input().split( )
i2 = int(input())
lt2 = input().split( )

Invalid = 0

for k in lt2:
    if k not in lt1:
        Invalid=Invalid+1
for w in lt1:
    print(w+' : '+str(lt2.count(w)))
print('Invalid :',Invalid)

【牛客站内】华为机试题练习记录

全部评论

相关推荐

程序员小白条:你不是有一段实习了吗,现在找中大厂实习?过段时间要秋招了
我的简历长这样
点赞 评论 收藏
分享
06-28 22:48
已编辑
广东金融学院 Java
小浪_Coding:学院本+这俩项目不是buff叠满了嘛
点赞 评论 收藏
分享
评论
2
2
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务