Hi Melody: I don't see any "bugs" in the code !. C=20. [20^3 - 20 =7980 mod 12 =0]......etc. Here are the results of all the 60 numbers that I have listed. Here is another short code taking them to "mod 12" and they all give "zero", which means they are ALL multiples of 12.
listforeach(n, d=(7980 , 9240 , 12144 , 13800 , 15600 , 19656 , 21924 , 24360 , 29760 , 32736 , 35904 , 42840 , 46620 , 50616 , 59280 , 63960 , 68880 , 79464 , 85140 , 91080 , 103776 , 110544 , 117600 , 132600 , 140556 , 148824 , 166320 , 175560 , 185136 , 205320 , 215940 , 226920 , 249984 , 262080 , 274560 , 300696 , 314364 , 328440 , 357840 , 373176 , 388944 , 421800 , 438900 , 456456 , 492960 , 511920 , 531360 , 571704 , 592620 , 614040 , 658416 , 681384 , 704880 , 753480 , 778596 , 804264 , 857280 , 884640 , 912576 , 970200), c=n%12)
OUTPUT=(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0)