Last active
April 8, 2019 06:20
-
-
Save Maxcutex/8afe0bb2a4e3aab200d4b0678a3d816f to your computer and use it in GitHub Desktop.
Election Project - Step Two election file
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
contract Election { | |
// Model a Candidate | |
struct Candidate { | |
uint id; | |
string name; | |
uint voteCount; | |
} | |
// Read/write Candidates | |
mapping(uint => Candidate) public candidates; | |
// Store Candidates Count | |
uint public candidatesCount; | |
// ... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment