def set_n_digits(n):
    """
    Sets the number of digits "after the dot" you want to print.  
    For example if you call `set_n_digits(3)` and then `print(my_qubit)`  
    the result will be something like `'+0.707|0> +0.707|1>'`
    """
    if not isinstance(n, int):
        raise TypeError('The number of digits must be an int')
    if n < 1:
        raise ValueError('Number of digits too low')
    global num_format
    num_format = '{:+.' + str(n) + '}'
