Solidity REPL
Encoding & crypto

SHA-256 and RIPEMD-160

Compare Solidity’s SHA-256 and RIPEMD-160 cryptographic helpers.

Solidity 0.8.36REPL mode

Why use this example

Use this pattern when you need to check the exact bytes, selector, hash, or decoded values that Solidity will produce. The entry isolates sha-256 and ripemd-160 so its input, result, and state changes stay easy to compare.

Solidity to run

bytes memory input = bytes("hello")
sha256(input)
ripemd160(input)

Official Solidity reference

Compare this focused investigation with the complete language definition in the Solidity documentation.

Cryptographic functions

What to expect

The same input bytes produce visible bytes32 SHA-256 and bytes20 RIPEMD-160 digests.

Continue the investigation

Change a value, add another expression, or open Inspect after the run. Accepted entries remain available to the next entry, and the clean replay keeps the complete result reproducible.

Read about values and inspection Prototype Solidity behavior