<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def rotatePoints(points, rotationDegrees, pivotx=0, pivoty=0):
 """ Rotates each x and y tuple in `points`` by `rotationDegrees`. The points are rotated around the origin by default, but can be rotated around another pivot point by specifying `pivotx` and `pivoty`. The points are rotated counterclockwise. Returns a generator that produces an x and y tuple for each point in `points`. [(7, 7), (0, 9)] """


    rotationRadians = math.radians(rotationDegrees % 360)

    for x, y in points:
        _checkForIntOrFloat(x)
        _checkForIntOrFloat(y)
        x -= pivotx
        y -= pivoty
        x, y = x * math.cos(rotationRadians) - y * math.sin(rotationRadians), x * math.sin(rotationRadians) + y * math.cos(rotationRadians)
        x += pivotx
        y += pivoty

        yield int(x), int(y)