Love丶FFC's Blog
月饼是久负盛名的中国传统糕点之一,自唐朝以来,已经发展出几百品种。
若想评比出一种“最好吃”的月饼,那势必在吃货界引发一场腥风血雨…… 在这里我们用数字说话,给出全国各地各种月饼的销量,要求你从中找出销量冠军,认定为最好吃的月饼。
输入首先给出两个正整数 N(≤1000)和 M(≤100),分别为月饼的种类数(于是默认月饼种类从 1 到 N 编号)和参与统计的城市数量。
接下来 M 行,每行给出 N 个非负整数(均不超过 1 百万),其中第 i 个整数为第 i 种月饼的销量(块)。数字间以空格分隔。
在第一行中输出最大销量,第二行输出销量最大的月饼的种类编号。如果冠军不唯一,则按编号递增顺序输出并列冠军。数字间以 1 个空格分隔,行首尾不得有多余空格。
5 3
1001 992 0 233 6
8 0 2018 0 2008
36 18 0 1024 4
2018
3 5
1.题目已经说明,输入的第i个整数为第i种月饼的销量
2.按照这一点,提前创建一个列表,并且把每个值都初始化为0
3.按照编号递增进行销量冠军的筛选
NOM, NOC = map(int, input().split()) # 输入月饼种类的个数、参与统计的城市个数 MoonCake = [0 for i in range(NOM)] # 存放每种月饼的销量 ChampionID = list() # 存放销量最好的月饼的编号 for i in range(NOC): Sales = list(map(int, input().split())) for j in range(len(Sales)): # 遍历一行输入 MoonCake[j] += Sales[j] # 增加对应索引的月饼销量 for i in range(NOM): if MoonCake[i] == max(MoonCake): ChampionID.append(i + 1) # 按照编号递增顺序,添加销量最好的月饼编号 print(max(MoonCake)) for i in range(len(ChampionID)): # 按格式输出 if i != len(ChampionID) - 1: print(ChampionID[i], end=' ') else: print(ChampionID[i])
authentic cheap jordans
I just wanted to thank you for the fast service. and they look great. I received them a day earlier than expected. the same as the I will definitely continue to buy from this site. in either case I will recommend this site to my friends. Thanks!
authentic cheap jordans https://www.realcheapretrojordanshoes.com/
cheap louis vuitton outlet
I just wanted to thank you for the fast service. and even they look great. I received them a day earlier than expected. exactly like the I will definitely continue to buy from this site. situation I will recommend this site to my friends. Thanks!
cheap louis vuitton outlet https://www.bestlouisvuittonoutlet.com/
cheap louis vuitton outlet
I just wanted to thank you for the fast service. potentially they look great. I received them a day earlier than expected. enjoy the I will definitely continue to buy from this site. in either case I will recommend this site to my friends. Thanks!
cheap louis vuitton outlet https://www.cheapreallouisvuitton.com/
original louis vuittons outlet
I just wanted to thank you for the fast service. or even a they look great. I received them a day earlier than expected. such I will definitely continue to buy from this site. you ultimately choose I will recommend this site to my friends. Thanks!
original louis vuittons outlet https://www.louisvuittonsoutletstore.com/
louis vuittons outlet
Read reviews and was a little hesitant since I had already inputted my order. or even but thank god, I had no issues. love the received item in a timely matter, they are in new condition. you ultimately choose so happy I made the purchase. Will be definitely be purchasing again.
louis vuittons outlet https://www.louisvuittonsoutlet.com/
cheap jordans online
Read reviews and was a little hesitant since I had already inputted my order. and even but thank god, I had no issues. choose to received item in a timely matter, they are in new condition. blue jays so happy I made the purchase. Will be definitely be purchasing again.
cheap jordans online https://www.realjordansretro.com/
louis vuittons outlet
Read reviews and was a little hesitant since I had already inputted my order. maybe but thank god, I had no issues. particularly received item in a timely matter, they are in new condition. regardless so happy I made the purchase. Will be definitely be purchasing again.
louis vuittons outlet https://www.louisvuittonsoutletonline.com/
FoorryNox
There are some lifestyle changes that can help you work through these changes, including generic cialis from india
gucci.com sale handbags
What is the recycling price of GUCCI’s “highest value” classic bags?
cheap authentic
$ 93.18Cheap Jordan 4 Women “Cement ash“
classic gucci bags
NO.3MK Whitney small shoulder bag ¥4300 MK This Whitney shoulder bag has simple lines and an adjustable chain strap. It is double-folded and suitable for commuting. The leather is made of rare lambskin, which is softer and more delicate than lambskin, and the metal buckle adds a sense of gorgeousness.
gucci handbags outlet canada
Sylvie1969 series is a series that is very suitable for commuting to work. 1969 is full of aura and full of business elites.
Retro Air Jordan Shoes
Cheap Jordan 11, Platinum Tint, for sale After seeing the real thing, it is planted! Cheap Jordan 11 “Platinum Tint” Appreciate your feet!
Preliaf
1971; 33 970 9 pastillas priligy en mexico
barSosz
Two patients experienced adverse events that required ceritinib dose reductions buy priligy
Fvcahe
buy tricor generic buy fenofibrate 160mg online order tricor online
Qjbpcu
order zaditor without prescription buy cheap generic ziprasidone tofranil 75mg without prescription
Nlrslf
order cialis 5mg generic sildenafil 100mg ca sildenafil next day
Qqexqm
precose pills order fulvicin 250 mg without prescription buy griseofulvin 250 mg generic
Yuyoml
buy minoxytop paypal tamsulosin 0.2mg canada ed pills