For example, I have a nth block and when n + 1 th block is propagated, i have to compare with n+1 block's previous hash and nth block's hash for validation. It is pretty trivial.
But do i have to compare hash value for validation from genesis block to n + 1 block?
like comparing 0 and 1, 1 and 2, 2, and 3 ... n and n + 1
One of the most famous pseudo block chain code in github https://github.com/dvf/blockchain/blob/master/blockchain.py#L37, block is validated from genesis block.
Bitcoin use similar way to validate a new block?