0 out of 464 challenges solved
The Lucas sequence is a series of integers closely related to the Fibonacci sequence. The first two numbers in the Lucas sequence are 2 and 1, and each subsequent number is the sum of the two preceding numbers. Write a function `find_lucas(n)` that computes the n-th Lucas number. #### Examples ```python [main.nopy] find_lucas(0) # Output: 2 find_lucas(1) # Output: 1 find_lucas(5) # Output: 11 find_lucas(9) # Output: 76 ``` #### Constraints - The input `n` will be a non-negative integer. - The function should use recursion to compute the result.
def find_lucas(n): """ Compute the n-th Lucas number using recursion. Args: n (int): The index of the Lucas number to compute. Returns: int: The n-th Lucas number. """ # Base cases # Add recursive logic here pass