Skip to content

Instantly share code, notes, and snippets.

@danicuki
Last active July 12, 2022 15:49
Show Gist options
  • Save danicuki/d711eb23846732d472c7b366b5701caa to your computer and use it in GitHub Desktop.
Save danicuki/d711eb23846732d472c7b366b5701caa to your computer and use it in GitHub Desktop.
Homework - 2 givers - 1 receiver
{"valueParameterInfo":[["Deposit",{"valueParameterFormat":{"contents":[6,""],"tag":"DecimalFormat"},"valueParameterDescription":"Amount Deposited"}]],"timeParameterDescriptions":[],"roleDescriptions":[],"contractType":"Other","contractShortDescription":"Unknown","contractName":"Unknown","contractLongDescription":"We couldn't find information about this contract","choiceInfo":[]}
When
[Case
(Deposit
(Role "Giver1")
(Role "Giver1")
(Token "" "")
(ConstantParam "Deposit")
)
(When
[Case
(Deposit
(Role "Giver2")
(Role "Giver2")
(Token "" "")
(ConstantParam "Deposit")
)
(Pay
(Role "Giver1")
(Party (Role "Receiver"))
(Token "" "")
(ConstantParam "Deposit")
(Pay
(Role "Giver2")
(Party (Role "Receiver"))
(Token "" "")
(ConstantParam "Deposit")
Close
)
)]
(TimeParam "Deadline")
Close
), Case
(Deposit
(Role "Giver2")
(Role "Giver2")
(Token "" "")
(ConstantParam "Deposit")
)
(When
[Case
(Deposit
(Role "Giver1")
(Role "Giver1")
(Token "" "")
(ConstantParam "Deposit")
)
(Pay
(Role "Giver1")
(Party (Role "Receiver"))
(Token "" "")
(ConstantParam "Deposit")
(Pay
(Role "Giver2")
(Party (Role "Receiver"))
(Token "" "")
(ConstantParam "Deposit")
Close
)
)]
(TimeParam "Deadline")
Close
)]
(TimeParam "Deadline")
Close
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment