Advertisement
sawczakl

Elegance 1

Jan 21st, 2024
822
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.20 KB | Writing | 0 0
  1. # Some properties of a given circle
  2.  
  3. # A
  4.  
  5. r = 5
  6. d = 2 * r
  7. c = 2 * math.pi * r
  8. a = math.pi * (r ** 2)
  9.  
  10. # B
  11.  
  12. r = 5
  13. d = 10
  14. c = 31.41592653589793
  15. a = 78.53981633974483
  16.  
  17. # Which is better, and why?
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement