# How to prevent crypto while allowing string idx, etc in CnR

In my new sandboxed challenge, I'm looking to ban crypto / one-way functions that make it impossible to get the input from the output.

I started out requiring only using functions that are bijectve, but that bans functions that "gets a character from a particular index of a string", as pointed out by aschepler.

I would like to ban crypto / one-way functions that make the challenge not fun, while allowing functions that get a char from an index in a string, etc. How can I do this? I'd prefer something that's worked in the past.

• You can just have a rule to explicitly ban "hashing, encryption, or random number generation." That's worked in the past. – AdmBorkBork Jul 24 '17 at 14:35
• I think that a[b] is pretty much one-way (e.g. 'The quick fox jumps over the lazy dog'[10] would return 'f' and there's no way to figure out where did the 'f' come from). – Erik the Outgolfer Jul 24 '17 at 14:35
• Requiring bijective functions wouldn't prevent one-way functions anyway. – Peter Taylor Jul 24 '17 at 15:01
• @PeterTaylor I think that bijective functions always have an inverse, since every value maps to only one value, and is mapped to by only one value too. – Erik the Outgolfer Jul 24 '17 at 15:05
• @EriktheOutgolfer, existence is not the point. Computability is the point: it's easy to compute in the forward direction, but hard in the inverse direction. – Peter Taylor Jul 24 '17 at 15:07