摘要: 不同于C语言和SHELL,python中没有switch case语句,关于为什么没有,官方的解释是这样的使用Python模拟实现的方法: def switch_if(fun, x, y): if fun == 'add': return x + y elif fun == 'sub': retur 阅读全文
posted @ 2018-11-20 18:18 丁壮 阅读(49740) 评论(0) 推荐(1) 编辑