提高级
摘要:
#二分开方 x = 2 low = 0.0 high = x guess = (low+high)/2 while abs(guess**2-x) >1e-4: if guess**2 >x: high = guess else: low = guess guess = (low +high) /2 print (guess) 1.41... 阅读全文
posted @ 2018-10-25 22:19 cltt 阅读(123) 评论(0) 推荐(0) 编辑