def checkLuckyDigit(num):
    if num == 0:
        return False
    elif (num%10) == 8:
        return True
    else:
        checkLuckyDigit(num//10)
num = int(input("Enter a number = "))
if(checkLuckyDigit(num)):
    print("There is a lucky digit")
else:
    print("There is no lucky digit")
In the above code i need to find out whether the user entered number has 8 in it or not , when i enter 4348 it displays There is a lucky digit but when i enter 3438434 it displays There is no lucky digit and the function returns None.
I recently moved from C++ to python so i am really confused what my mistake is.
 
     
    