def input_or(prompt, default='y'):
    """
    get input from command-line,
    if  the input is ommited by an enter key, then the default values is returned.
    """
    v = input(prompt + '(default:%s):' % str(default))
    v = v or default
    dtype = type(default)
    return dtype(v)
