Guest User

Untitled

a guest
Jan 19th, 2019
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. package block
  2.  
  3. import (
  4. "time"
  5. )
  6.  
  7. type Block struct {
  8. Index int
  9. PreviousHash string
  10. Data string
  11. Timestamp time.Time
  12. Difficulty int
  13. Hash string
  14. Nonce int
  15. }
  16.  
  17.  
  18. func CreateBlock() Block {
  19. var block Block
  20.  
  21. block.Timestamp = time.Now()
  22. block.Nonce = 0
  23.  
  24. return block
  25. }
Add Comment
Please, Sign In to add comment