mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
13 lines
314 B
Solidity
13 lines
314 B
Solidity
|
contract c {
|
||
|
bytes data;
|
||
|
|
||
|
function foo() public returns (bytes32) {
|
||
|
data.push("x");
|
||
|
data.push("y");
|
||
|
data.push("z");
|
||
|
return keccak256(abi.encodePacked("b", keccak256(data), "a"));
|
||
|
}
|
||
|
}
|
||
|
// ----
|
||
|
// foo() -> 0xb338eefce206f9f57b83aa738deecd5326dc4b72dd81ee6a7c621a6facb7acdc
|