Write a Python function to return cullen number


Topic: Write a Python function to return cullen number

Solution

def cullen_number(n):
    if n >= 0:
        return n * 2 ** n + 1
  



List all Python Programs