Ad
  • Custom User Avatar

    I'm a newbie, could anyone developp what it's meant by raising an error ? I did something like this. How to properly handle the error in this case ?

    def Is_Prime (number):
        try:
            if number == 0:
                statement 1
            else:
                for i in range(3,number):
                  statement 2
        except TypeError:
            return ('Error')