import mathfrom pwn import*# A utility function that returns true if x is perfect squaredefisPerfectSquare(x): s =int(math.sqrt(x))return s*s == x# Returns true if n is a Fibinacci Number, else falsedefisFibonacci(n):# n is Fibinacci if one of 5*n*n + 4 or 5*n*n - 4 or both# is a perferct squarereturnisPerfectSquare(5*n*n +4)orisPerfectSquare(5*n*n -4)conn =remote('umbccd.io', 6000)done =Falsewhilenot done:print(conn.recvuntil('[')) arr =eval('['+ conn.recvline().decode())print(arr)print(conn.recv())for num in arr:ifisFibonacci(num):print(num) conn.send(str(num) +'\r\n')breakprint(conn.recv())conn.close()