# Ultimate Go: Advanced Engineering Episode 19 -- Defining a Blockchain Account Data Structure

DevFeed: [Ultimate Go: Advanced Engineering Episode 19 -- Defining a Blockchain Account Data Structure](<https://devfeed.tech/articles/ultimate-go-advanced-engineering-episode-19-22208.md>)

Original publisher: [Read original article](<https://www.ardanlabs.com/blog/2023/01/ultimate-go-advanced-engineering-episode-19.html>)

Published: 2023-01-24T00:00:00Z

Content type: tutorial

Language: en

Sources: [William Kennedy](<https://devfeed.tech/sources/william-kennedy.md>)

Topics: [Go Language](<https://devfeed.tech/topics/go-language.md>), [Blockchain](<https://devfeed.tech/topics/blockchain.md>), [Data structures](<https://devfeed.tech/topics/data-structures.md>), [Ethereum](<https://devfeed.tech/topics/ethereum.md>), [Transactions](<https://devfeed.tech/topics/transactions.md>)

Tags: [account](<https://devfeed.tech/tags/account.md>), [bitcoin](<https://devfeed.tech/tags/bitcoin.md>), [blockchain](<https://devfeed.tech/tags/blockchain.md>), [data-structure](<https://devfeed.tech/tags/data-structure.md>), [data-type](<https://devfeed.tech/tags/data-type.md>), [design](<https://devfeed.tech/tags/design.md>), [engineering](<https://devfeed.tech/tags/engineering.md>), [ethereum](<https://devfeed.tech/tags/ethereum.md>), [factory-function](<https://devfeed.tech/tags/factory-function.md>), [go](<https://devfeed.tech/tags/go.md>), [go-blockchain](<https://devfeed.tech/tags/go-blockchain.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [learn](<https://devfeed.tech/tags/learn.md>), [transactions](<https://devfeed.tech/tags/transactions.md>), [video](<https://devfeed.tech/tags/video.md>)

## AI overview

This video explains how to define a user account type for a blockchain in Go. It covers the account data structure, the design rationale, and a factory function for initializing an account.

## Source excerpt

Introduction In episode 18, Bill defined the Go type that will represent a transaction and implemented the methods to validate one. While developing the transaction type, Bill states that he'll be borrowing concepts from Ethereum to ensure that he's building a reference implementation. Bill's transaction type has a field named nonce, similar to Ethereum, that ensures transactions are executed in order. The nonce value of the last transaction is stored in his accounting database and later compared for additional verification.