mirror of
https://hub.njuu.cf/TheAlgorithms/Python.git
synced 2023-10-11 13:06:12 +08:00
Updated gamma
This commit is contained in:
parent
1d4fc814fa
commit
7bd84b4eee
@ -5,12 +5,12 @@ for more info: https://en.wikipedia.org/wiki/Gamma_function
|
||||
"""
|
||||
|
||||
# Importing packages
|
||||
from math import sqrt, pi
|
||||
from math import pi, sqrt
|
||||
from re import match
|
||||
from typing import Union
|
||||
|
||||
|
||||
def gamma(num : Union[int, float]) -> Union[int, float]:
|
||||
def gamma(num: Union[int, float]) -> Union[int, float]:
|
||||
"""
|
||||
Calculates the value of Gamma function of num
|
||||
where num is either an integer (1,2,3..) or a half-integer (0.5,1.5,2.5...).
|
||||
|
Loading…
Reference in New Issue
Block a user