document.write('
Data hosted with ♥ by Pastebin.com - Download Raw - See Original
  1. def main():
  2.     p = 17
  3.     g = 11
  4.     X = 4
  5.     Y = 10
  6.     res = 1
  7.     xc = list()
  8.     yc = list()
  9.     for i in range(p):
  10.         pot = i + 1
  11.         res *= g
  12.         res %= p
  13.         if res == X:
  14.             print \'x = %d\' % pot
  15.             xc.append(pot)
  16.         if res == Y:
  17.             print \'y = %d\' % pot
  18.             yc.append(pot)
  19.         print \'g^%d = %d\' % (pot, res)
  20.  
  21.     for x in xc:
  22.         for y in yc:
  23.             k = (g ** (x * y)) % p
  24.             print \'k = %d\' % k
  25. main()
');