mirror of
https://github.com/pezkuwichain/revive.git
synced 2026-06-13 17:41:05 +00:00
switch to pallet_revive runtime (#40)
Signed-off-by: xermicus <cyrill@parity.io>
This commit is contained in:
@@ -2,7 +2,29 @@
|
||||
|
||||
pragma solidity ^0.8;
|
||||
|
||||
// https://medium.com/coinmonks/fibonacci-in-solidity-8477d907e22a
|
||||
/* runner.json
|
||||
{
|
||||
"actions": [
|
||||
{
|
||||
"Instantiate": {}
|
||||
},
|
||||
{
|
||||
"Call": {
|
||||
"dest": {
|
||||
"Instantiated": 0
|
||||
},
|
||||
"data": "6b83dd2e0000000000000000000000000000000000000000000000000000000000000006"
|
||||
}
|
||||
},
|
||||
{
|
||||
"VerifyCall": {
|
||||
"success": true,
|
||||
"output": "0000000000000000000000000000000000000000000000000000000000000008"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
*/
|
||||
|
||||
contract FibonacciRecursive {
|
||||
function f(uint n) internal pure returns (uint) {
|
||||
@@ -36,6 +58,7 @@ contract FibonacciIterative {
|
||||
}
|
||||
}
|
||||
|
||||
// https://medium.com/coinmonks/fibonacci-in-solidity-8477d907e22a
|
||||
contract FibonacciBinet {
|
||||
function fib3(uint n) external pure returns (uint a) {
|
||||
if (n == 0) {
|
||||
|
||||
Reference in New Issue
Block a user