题解 | #发送offer#

发送offer

https://www.nowcoder.com/practice/66969869634b4142ac371684fcf89764

offer_list = ["Allen", "Tom"]
for name in offer_list:
    print("%s, you have passed our interview and will soon become a member of our company."% name)
offer_list[1]="Andy"
for name2 in offer_list:
    print("%s, welcome to join us!"% name2)
1、替换列表中的名字
2、打印名字的方法——这个f'{ }' 具体有啥作用?谁能指点一下?
offer_list = ["Allen","Tom"]

for name in offer_list:
    print(f"{name}, you have passed our interview and will soon become a member of our company.")

offer_list.remove("Tom")
offer_list.append("Andy")

for name2 in offer_list:
    print(f"{name2}, welcome to join us!")

#做题#
全部评论

相关推荐

点赞 评论 收藏
分享
星辰再现:裁员给校招生腾地方
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

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