SEND + MORE = MONEY: Difference between revisions
→{{header|Wren}}: More efficient.
Thundergnat (talk | contribs) m (→Fast: Add optimizations and timing) |
(→{{header|Wren}}: More efficient.) |
||
Line 294:
for (or in ors) {
if (send.contains(or[0]) || send.contains(or[1])) continue
var MORE = 1000 * m + 100 * or[0] + 10 * or[1] + send[1]
for (y in digits) {
if (
var MONEY = 10000 * m + 1000 * or[0] + 100 * send[2] + 10 * send[1] + y
if (SEND + MORE == MONEY) {
Line 312 ⟶ 311:
9567 + 1085 = 10652
Took 0.
</pre>
|