t998.py 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. import math
  2. print "ceil",type(math.ceil(3)),math.ceil(3)
  3. print "fabs",type(math.fabs(3)),math.fabs(3)
  4. print "factorial",type(math.factorial(3)),math.factorial(3)
  5. print "floor",type(math.floor(3)),math.floor(3)
  6. #print "fmod",type(math.fmod(3,1)),math.fmod(3,1)
  7. #print "frexp",type(math.frexp(3)),math.frexp(3)
  8. #print "fsum",type(math.fsum([1,2,3])),math.fsum([1,2,3])
  9. #print "isinf",type(math.isinf(3)),math.isinf(3)
  10. #print "isnan",type(math.isnan(3)),math.isnan(3)
  11. #print "ldexp",type(math.ldexp(3,1)),math.ldexp(3,1)
  12. #print "modf",type(math.modf(3)),math.modf(3)
  13. print "trunc",type(math.trunc(3)),math.trunc(3)
  14. print "exp",type(math.exp(3)),math.exp(3)
  15. print "log",type(math.log(3)),math.log(3)
  16. #print "log1p",type(math.log1p(3)),math.log1p(3)
  17. #print "log10",type(math.log10(3)),math.log10(3)
  18. print "pow",type(math.pow(3,3)),math.pow(3,3)
  19. print "sqrt",type(math.sqrt(9)),math.sqrt(9)
  20. print "acos",type(math.acos(1)),math.acos(1)
  21. print "asin",type(math.asin(1)),math.asin(1)
  22. print "atan",type(math.atan(3)),math.atan(3)
  23. print "atan2",type(math.atan2(3,3)),math.atan2(3,3)
  24. print "cos",type(math.cos(3)),math.cos(3)
  25. print "hypot",type(math.hypot(3,4)),math.hypot(3,4)
  26. print "sin",type(math.sin(3)),math.sin(3)
  27. print "tan",type(math.tan(3)),math.tan(3)
  28. print "degrees",type(math.degrees(math.pi)),math.degrees(3)
  29. print "radians",type(math.radians(3)),math.radians(3)
  30. #print "acosh",type(math.acosh(1)),math.acosh(1)
  31. #print "asinh",type(math.asinh(1)),math.asinh(1)
  32. #print "cosh",type(math.cosh(3)),math.cosh(3)
  33. #print "sinh",type(math.sinh(3)),math.sinh(3)
  34. #print "tanh",type(math.tanh(3)),math.tanh(3)
  35. #print "erf",type(math.erf(1)),math.erf(1)
  36. #print "erfc",type(math.erfc(1)),math.erfc(1)
  37. #print "gamma",type(math.gamma(3)),math.gamma(3)
  38. #print "lgamma",type(math.lgamma(3)),math.lgamma(3)
  39. print "pi",type(math.pi),math.pi
  40. print "e",type(math.e),math.e