This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// You might expect | |
try { | |
eval('asdfjkl'); | |
} catch (err) { | |
console.log(err); | |
} | |
// Also works, prints the same | |
try { | |
asdfjkl |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Inspired by https://medium.com/sons-of-javascript/javascript-circus-freaks-and-rascals-4e65ef3579d4 | |
var Ӷノಥ益ಥⱹノ彡 = function(err) { throw err; }; | |
var ___ = new Error("Table flipped"); | |
Ӷノಥ益ಥⱹノ彡(___) // Uncaught Error: Table flipped |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pickle | |
from math import log, ceil, floor | |
def encodetoint(str): | |
str = pickle.dumps(str) | |
base = 256 | |
val = 0 | |
for i in xrange(len(str)): | |
val += base ** i * ord(str[i]) | |
return val |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pickle | |
def xorswap(a, b): | |
a = a ^ b | |
b = a ^ b | |
a = a ^ b | |
return (a, b) | |
def main(): | |
a = "Lololol" |