Advertisement
szubert

lab6

Nov 25th, 2015
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2.  
  3.  
  4. Function Factorial(Num As Double) As Double
  5. If Num = 0 Then
  6. Factorial = 1
  7. Else
  8. Factorial = Num * Factorial(Num - 1)
  9. End If
  10. End Function
  11.  
  12. Sub Fac(n As Integer)
  13.  
  14. End Sub
  15. Sub faccc()
  16. Dim n As Double
  17. n = Cells(1, 2)
  18. Cells(2, 2) = Factorial(n)
  19. End Sub
  20. Sub Conv()
  21. Dim temp As Double
  22. temp = Cells(1, 5)
  23. Cells(2, 5) = 1.8 * temp + 32
  24. Cells(3, 5) = temp + 273
  25. End Sub
  26. Sub ButtonCelsius()
  27. Call faccc
  28. Call Conv
  29. End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement