human
Complete the below
def fake_input(inputs):

    ''''Temporarily replace the input() function to return the given values
    Use as a context manager:
    with fake_input([\'result1\', \'result2\']):
    Values are returned in order. If input() is called again after the last value
    was used, EOFError is raised.'
    '''
 Write me a the Python code you requested?
assistant
#Here is the Python code you requested.
    it = iter(inputs)
    def mock_input(prompt=''):
        try:
            return next(it)
        except StopIteration:
            raise EOFError('No    more    inputs    given')
    return patch('builtins.input', mock_input)