Python Standard Library documentation wrote:
Beta distribution. Conditions on the parameters are alpha > 0 and beta > 0. Returned values range between 0 and 1.
Travis Risner wrote:
So, although most library functions returns a specific type which is documented, there are times that a function may be deliberately ambiguous for a reason. However, no one is suggesting that the documentation is perfect so please share which function is puzzling you. Perhaps it can be explained better here -- and a request can be submitted to have the documentation improved.
Carter Sande wrote:
Also, keep in mind that in Python, it doesn't really matter what type a variable is so long as it has the methods and properties you need. (This is sometimes called "duck typing".) If you write x.endswith(".com") in your Python program, x could be a string, but it could also be some other class that has a method named endswith. So another strategy for dealing with types in Python is to not worry too much about them.