<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def replace(string, data):
 """ Replaces the data occurrences in the string. Usage:: "Z6PO" : "R2D2"}) u'Users are: Luke Skywalker, Anakin Skywalker, R2D2.' :param string: String to manipulate. :type string: unicode :param data: Replacement occurrences. :type data: dict :return: Manipulated string. :rtype: unicode """


    for old, new in data.iteritems():
        string = string.replace(old, new)
    return string