この記事を三行にまとめると
足し算の挙動の違いを利用する文字列のインデックス指定を利用する
JavaScriptでできることは一通りできる
この記事は以下の動画の中に出てきたサンプルコードを載せたものです。コピペなどが必要なときに使ってください。
alert(0)を実行するコード
[][(![]+[])[+!![]]+(!![]+[])[+[]]][([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[!![]+!![]+!![]]+(([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[!![]+!![]+!![]+!![]+!![]+!![]])+(([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[!![]+!![]])+((![]+[])[!![]+!![]+!![]])+((!![]+[])[+[]])+((!![]+[])[+!![]])+((!![]+[])[!![]+!![]])+(([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[!![]+!![]+!![]])+((!![]+[])[+[]])+(([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[!![]+!![]+!![]+!![]+!![]+!![]])+((!![]+[])[+!![]])]((![]+[])[+!![]]+(![]+[])[!![]+!![]]+(!![]+[])[!![]+!![]+!![]]+(!![]+[])[+!![]]+(!![]+[])[+[]]+([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[(+!![]+[])+(+!![])]+(+[])+([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[(+!![]+[])+(!![]+!![])])();
各パーツについて
// 0
+[]
// a(false[1])
(![]+[])[+!![]]
// l(false[2])
(![]+[])[!![]+!![]]
// e(true[3])
(!![]+[])[!![]+!![]+!![]]
// r(true[1])
(!![]+[])[+!![]]
// t(true[0])
(!![]+[])[+[]]
// alert
(![]+[])[+!![]]+(![]+[])[!![]+!![]]+(!![]+[])[!![]+!![]+!![]]+(!![]+[])[+!![]]+(!![]+[])[+[]]
// at(fasle[1]+true[0])
(![]+[])[+!![]]+(!![]+[])[+[]]
// []["at"]
[][(![]+[])[+!![]]+(!![]+[])[+[]]]+[]
// constructor
([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[!![]+!![]+!![]]+(([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[!![]+!![]+!![]+!![]+!![]+!![]])+(([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[!![]+!![]])+((![]+[])[!![]+!![]+!![]])+((!![]+[])[+[]])+((!![]+[])[+!![]])+((!![]+[])[!![]+!![]])+(([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[!![]+!![]+!![]])+((!![]+[])[+[]])+(([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[!![]+!![]+!![]+!![]+!![]+!![]])+((!![]+[])[+!![]])
// かっこ ([]["at"]+[])[11]、([]["at"]+[])[12]
([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[(+!![]+[])+(+!![])]
([][(![]+[])[+!![]]+(!![]+[])[+[]]]+[])[(+!![]+[])+(!![]+!![])]