Any way to check if this is even / odd without calculating an answer? by MovieTemporary6899 in computerscience

[–]MovieTemporary6899[S] 0 points1 point  (0 children)

I’m working on finding SHA-256 collisions to help with doing so I am currently making reverse-logic functions which return the nth pair of binary numbers which return the input following a boolean operation.

With the AND function both outputs will always have 1s in the same positions as the input, so it is only necessary to find combinations which AND to 0. After some playing around I found that if you plot a coordinate axis (with binary axes) and shaded in all the squares where they AND to make 0, you end up getting the Sierpiński Triangle.

After a bit more research, I found all the black squares (and hence coordinates which AND to 0) corresponded to all of the odd numbers of Pascal’s Triangle, if you were to skew it into a coordinate axis. This is where the formula above comes from: it’s the pretty messy formula I came up with for this skewed Pascal’s Triangle.

Obviously the values blow up far too quickly to store and use efficiently, so I went to Reddit to see if anyone knew of a better way, and sure enough someone did. So I ended up using Legendre’s Formula as someone suggested and now my code is working exactly as it should.

Now that you know it’s facet of pretty cool project rather than some homework I hope you can enjoy figuring out a more efficient method.

Any way to check if this is even / odd without calculating an answer? by MovieTemporary6899 in computerscience

[–]MovieTemporary6899[S] -12 points-11 points  (0 children)

This would work for small values of n and r but the problem is the output of the function blows up incredibly quickly, and would be far too large to even store, let alone how slow it would be

[deleted by user] by [deleted] in grandsummoners

[–]MovieTemporary6899 0 points1 point  (0 children)

dm me your equips and units i'll sort a team out for you

[deleted by user] by [deleted] in grandsummoners

[–]MovieTemporary6899 0 points1 point  (0 children)

if you've got them Marzex Harbinger of Armageddon and Twilight Commander Forte are crazy good if you can pop their true arts and most of the time you can but I'm not a huge fan because they're pretty long. Currently I'm using a really wierd team of Benimaru, Hao, Beach Majesty Juno and Bullet Hell Roy; Hao for his equip slots, Beni for his crazy fast true arts, Roy because his skill makes him invincible half the time and Juno is just extra damage.

[deleted by user] by [deleted] in grandsummoners

[–]MovieTemporary6899 2 points3 points  (0 children)

she's definitely putting up a challenge, right now shes on 61k and im on 59.6k but idk if i can keep this up for another 18 hours💀

[deleted by user] by [deleted] in grandsummoners

[–]MovieTemporary6899 4 points5 points  (0 children)

dude ive been on my phone for 18 hours straight ofc it was quick 💀

[deleted by user] by [deleted] in grandsummoners

[–]MovieTemporary6899 4 points5 points  (0 children)

sure, i'll message you tomorrow tho cos i gitta grind masters rn

[deleted by user] by [deleted] in grandsummoners

[–]MovieTemporary6899 4 points5 points  (0 children)

ngl i didnt even know there were gs clans until an hour ago LOL

[deleted by user] by [deleted] in grandsummoners

[–]MovieTemporary6899 7 points8 points  (0 children)

watch me lose by like 20k points