Skip to content

Commit

Permalink
Create blockchain.h
Browse files Browse the repository at this point in the history
  • Loading branch information
KOSASIH authored Aug 6, 2024
1 parent 523b438 commit 837fbde
Showing 1 changed file with 20 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#ifndef BLOCKCHAIN_H
#define BLOCKCHAIN_H

#include <vector>
#include "block.h"

class Blockchain {
public:
Blockchain();
~Blockchain();

void add_block(const std::vector<std::string>& transactions);
const std::vector<Block>& get_chain() const;

private:
std::vector<Block> chain_;
uint32_t difficulty_;
};

#endif // BLOCKCHAIN_H

0 comments on commit 837fbde

Please sign in to comment.