This is a block that encrypts things that cannot be decrypted again! It's widely used for authentication (passwords and messages), checking files (malware or viruses), etc. These are examples of how to use it:
Hashing passwords
Hashing messages
Hiding information
And many more uses! Now it has unlimited output length (the maximum recommended is 262144 though) since it generates the same number in the same position using the same string. Please tell me if this works fine now (or at least better than the prev one).
Source
Copy and Import:
<blocks app="Snap! 7, https://snap.berkeley.edu" version="2"><block-definition s="hash %'text' output length %'length'" type="reporter" category="operators"><header></header><code></code><translations></translations><inputs><input type="%txt">text</input><input type="%n">20<options>default=20
128 bits=38
224 bits=67
256 bits=77
512 bits=154</options></input></inputs><script><block s="doReport"><block s="reportJoinWords"><list><block s="reportAtomicMap"><block s="reifyReporter"><autolambda><block s="reportLetter"><l>1</l><block s="reportModulus"><block s="reportVariadicProduct"><list><block s="reportVariadicSum"><block var="value"/></block><block s="reportVariadicSum"><list><block s="reportModulus"><block var="index"/><l>5</l></block><l>6</l></list></block></list></block><l>100</l></block></block></autolambda><list><l>value</l><l>index</l></list></block><block s="reportListAttribute"><l><option>columns</option></l><block s="reportAtomicMap"><block s="reifyReporter"><autolambda><block s="reportReshape"><block s="reportTextSplit"><block s="reportRound"><block s="reportQuotient"><block var="value"/><block var="index"/></block></block><l><option>letter</option></l></block><list><block var="length"/></list></block></autolambda><list><l>value</l><l>index</l></list></block><block s="reportListAttribute"><l><option>reverse</option></l><block s="reportListAttribute"><l><option>columns</option></l><block s="reportAtomicMap"><block s="reifyReporter"><autolambda><block s="reportMonadic"><l><option>floor</option></l><block s="reportVariadicProduct"><list><block s="reportModulus"><block s="reportPower"><block s="reportVariadicProduct"><list><block var="list"/><block var="index"/></list></block><block s="reportQuotient"><l>1</l><l>11</l></block></block><block s="reportQuotient"><block s="reportListAttribute"><l><option>length</option></l><block var="list"/></block><block var="value"/></block></block><block s="reportMonadic"><l><option>10^</option></l><l>11</l></block></list></block></block></autolambda><list><l>value</l><l>index</l><l>list</l></list></block><block s="reportAtomicMap"><block s="reifyReporter"><autolambda><block s="reportMonadic"><l><option>ceiling</option></l><block s="reportVariadicProduct"><list><block var="value"/><block s="reportQuotient"><block var="index"/><block s="reportVariadicSum"><list><block s="reportStringSize"><block var="text"/></block><l>6</l></list></block></block></list></block></block></autolambda><list><l>value</l><l>index</l></list></block><block s="reportVariadicProduct"><list><block s="reportUnicode"><block s="reportJoinWords"><list><l>___</l><block var="text"/><l>___</l></list></block></block><l>11</l></list></block></block></block></block></block></block></block></block></list></block></block></script></block-definition></blocks>
(C) 2022 ScratchModification