I'm trying out Python 3 and been doing a practice with a while loop but the loop doesn't end when the variable is set to another value different from the default Y
#!/usr/bin/python3
elements = [];
copy = [];
rot=0;
op='y';
ap='y';
while op is 'y' or 'Y':
    elements = [];
    a = int(input("How many elements? "));
    for i in range(a):
        elements.append(input("Enter element " + str(i+1) + " "));
    while ap is 'y' or 'Y':
        rot = int(input("How many element to rotate? "));
        print(elements);
        copy = elements[-rot:] + elements[:-rot];
        elements = copy;
        print(elements);
        ap = input("Rotate again? ");
    op = input("Create a new rotatrix? ");
 
     
     
    