NP68. 毕业生就业调查
描述
输入描述
无输出描述
Python 解法, 执行用时: 10ms, 内存消耗: 2832KB, 提交时间: 2022-06-10
a = ["Niumei", "Niu Ke Le", "GURR", "LOLO"]; z = {"Niumei": "Nowcoder", "GURR": "Huawei"}; for b in a: if b in z: print("Hi, {}! Thank you for participating in our graduation survey!".format(b)); else: print("Hi, %s! Could you take part in our graduation survey?" % b);
Python 解法, 执行用时: 10ms, 内存消耗: 2836KB, 提交时间: 2022-08-04
survey_list=['Niumei','Niu Ke Le','GURR','LOLO'] result_dict={'Niumei':'Nowcoder','GURR':'HUAWEI'} for i in survey_list: if i in result_dict.keys(): print('Hi, {}! Thank you for participating in our graduation survey!'.format(i)) else: print('Hi, {}! Could you take part in our graduation survey?'.format(i))
Python 解法, 执行用时: 10ms, 内存消耗: 2836KB, 提交时间: 2022-07-15
survey_list = ['Niumei','Niu Ke Le','GURR','LOLO'] result_dict = {'Niumei': 'Nowcoder','GURR': 'HUAWEI'} for i in survey_list: if i in result_dict: print('Hi, '+i+'! Thank you for participating in our graduation survey!') else: print('Hi, '+i+'! Could you take part in our graduation survey?')
Python 解法, 执行用时: 10ms, 内存消耗: 2836KB, 提交时间: 2022-07-09
survey_list = ['Niumei','Niu Ke Le','GURR','LOLO'] result_dict = {'Niumei':'Nowcoder','GURR':'HUAWEI'} for i in survey_list: if i in result_dict: print('Hi, {}! Thank you for participating in our graduation survey!'.format(i)) else: print('Hi, {}! Could you take part in our graduation survey?'.format(i))
Python 解法, 执行用时: 10ms, 内存消耗: 2836KB, 提交时间: 2022-06-17
survey_list=['Niumei','Niu Ke Le','GURR','LOLO'] result_dict={'Niumei': 'Nowcoder','GURR': 'HUAWEI'} for i in survey_list: for j in result_dict: if i==j: print('Hi, %s! Thank you for participating in our graduation survey!'%i) break else: print('Hi, %s! Could you take part in our graduation survey?'%i)