#!/usr/bin/env python<span></span>import hashlibfor flag in range(0, 10000):<span>	      b = ((512 | flag ) ^ (318) ) & 1405</span><span>	      if b == 1337:</span><span>		            print flag</span><span>		            flag_sha256 = hashlib.sha256(str(flag)).hexdigest()</span><span>		            print "flag is : 3DS{"+flag_sha256+"}"</span><span>		            exit()</span>