def validinput(x0, xf, n):
    """Checks that the user input is valid.

    Args:
        x0 (float): Start value
        xf (float): End values
        n (int): Number of sample points

    Returns:
        False if x0 > xf or if
        True otherwise
    """
    valid = True
    if x0 > xf:
        valid = False
    if int(n) != n:
        valid = False
    if not valid:
        print("Please recheck your input")
    return valid