Last active
June 18, 2023 18:21
-
-
Save dk14/36b79f5ffa27903ade4db05a2f82fe53 to your computer and use it in GitHub Desktop.
EuropeanOption
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"valueParameterInfo":[],"timeParameterDescriptions":[],"roleDescriptions":[],"contractType":"Other","contractShortDescription":"Unknown","contractName":"Unknown","contractLongDescription":"We couldn't find information about this contract","choiceInfo":[]} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Let | |
"strike" | |
(Constant 35000) | |
(Let | |
"premium" | |
(Constant 100) | |
(Let | |
"notional" | |
(Constant 1000) | |
(Let | |
"collateral_bob" | |
(Constant 300) | |
(When | |
[Case | |
(Deposit | |
(Role "Bob") | |
(Role "Alice") | |
(Token "" "") | |
(UseValue "premum") | |
) | |
(When | |
[Case | |
(Deposit | |
(Role "Bob") | |
(Role "Bob") | |
(Token "" "") | |
(UseValue "collateral_bob") | |
) | |
(When | |
[Case | |
(Choice | |
(ChoiceId | |
"dummy" | |
(Address "invalid") | |
) | |
[Bound 1 2] | |
) | |
Close ] | |
1687041400572 | |
(When | |
[Case | |
(Choice | |
(ChoiceId | |
"WOLF_BTCADA_12121212_2121212" | |
(Address "oracle") | |
) | |
[Bound 0 1000000] | |
) | |
Close ] | |
1687041400572 | |
(Let | |
"market" | |
(ChoiceValue | |
(ChoiceId | |
"WOLF_BTCUSD_12121212_2121212" | |
(Address "oracle") | |
)) | |
(Let | |
"value" | |
(MulValue | |
(UseValue "notional") | |
(SubValue | |
(UseValue "market") | |
(UseValue "strike") | |
) | |
) | |
(If | |
(ValueLE | |
(UseValue "value") | |
(Constant 0) | |
) | |
Close | |
(Pay | |
(Role "Bob") | |
(Account (Role "Alice")) | |
(Token "" "") | |
(UseValue "value") | |
Close | |
) | |
) | |
) | |
) | |
) | |
)] | |
1687041400572 Close | |
)] | |
1687041400572 Close | |
) | |
) | |
) | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment