Last active
July 11, 2017 20:56
-
-
Save brynbellomy/03f9e536d033f81fe2a2df7a74a17ddf to your computer and use it in GitHub Desktop.
medium-return-struct-public-func-1.sol
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
pragma solidity 0.4.13; | |
contract Project | |
{ | |
struct Person { | |
string name; | |
uint funds; | |
} | |
mapping(address => Person) people; | |
function getBryn() | |
public | |
returns (Person) | |
{ | |
return Person({ name: "Bryn", funds: 123 }); | |
} | |
function getPerson(address id) | |
public | |
returns (Person) | |
{ | |
return people[id]; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment