摘要:
Exercise: In a factory a printer prints labels for boxes. For one kind of boxes the printer has to use colors which, for the sake of simplicity, are n 阅读全文
摘要:
exercise: Solution: def paperwork(n, m): return m*n if m>=0 and n>=0 else 0 def paperwork(n, m): return max(m,0) * max(n,0) 阅读全文
摘要:
Exercise: 奇偶判定:给两个整数判断是否是一奇数一偶数 solution: def lovefunc( flower1, flower2 ): return sum([flower1,flower2]) % 2 >0 :sum()函数 :% 求余数 阅读全文