Created
November 1, 2021 02:39
-
-
Save adityak74/722b9a7de697962c3d3c25fa94e5463c to your computer and use it in GitHub Desktop.
Revisions
-
adityak74 created this gist
Nov 1, 2021 .There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,10 @@ # The `contract` keyword defines a new contract type contract HelloWorld: message: String<100> pub fn __init__(self, _message: String<100>): self.message = _message pub fn update(self, newMessage: String<100>): self.message = newMessage pub fn getMessage(self) -> String<100>: return self.message.to_mem()