Activity: your first activity

Activities allow you to test you knowledge by practicing what you've learned. These take the form of small Rust projects that slowly build up on each other into something more advanced.

The goal of these is to eventually have you writing you own Blockchain from scratch, and being able to say you did it all yourself!

Starting an activity

You can find the code for activities on github. Create a fork of the repository and cd into the activities folder to complete each set of exercises.

Activities assume you are using the latest stable version of Rust and will provide all needed dependencies. Feel free to add new dependencies as you see fit, just try not to use anything that makes the job too easy for you. All tests will be run locally on your machine so that is not a problem.

A sample activity is provided for you to make sure everything compiles on your machine. Make sure that works before moving on!

Activity 1: Multiple choice quiz

Since the first section of this book has so far been more focused on abstracts concepts surrounding Blockchain, our first activity will not be a hands-on project.

Don't worry, the next activity will be hands on!

#![allow(unused)]
fn main() {
// TODO:
// > What is the main purpose of a Blockchain technologies?
// >
// > - a) To create digital currencies.
// > - b) To replace traditional banking systems.
// > - c) To achieve mathematical consensus in a narrative.
// >
pub fn question_0() -> char {
    todo!()
}

// TODO:
// > In the context of the high school marble problem, what does "consensus" mean?
// >
// > - a) When players finish the game.
// > - b) When multiple parties come to an agreement on the state of the game.
// > - c) When one player convinces others to give up their marbles.
// >
pub fn question_1() -> char {
    todo!()
}

// TODO:
// > Which of the following is NOT true about Web 2.0 services?
// >
// > - a) Web 2.0 is centralized.
// > - b) Web 2.0 requires trust in service providers
// > - c) Web 2.0 is inherently cryptographically secure.
// >
pub fn question_2() -> char {
    todo!()
}

// TODO:
// > What does it mean for Blockchain to be a "continuation of Humanity's history of
// > shared storytelling"?
// >
// > - a) Blockchain is primarily used for writing fiction.
// > - b) Blockchain allows for a fixed, unchangeable narrative over time.
// > - c) Blockchain is vulnerable to degradation like oral traditions.
// >
pub fn question_3() -> char {
    todo!()
}

// TODO:
// > Why is Web 3.0 arguably more democratic than Web 2.0?
// >
// > - a) It doesn't require trust in centralized entities.
// > - b) It allows for direct voting on all decisions.
// > - c) It's controlled by elected representatives.
// >
pub fn question_4() -> char {
    todo!()
}

// TODO:
// > What is described as potentially the greatest hurdle for Web 3.0 to overcome?
// >
// > - a) Technical limitations of blockchain technology.
// > - b) Government regulations.
// > - c) Crypto-literacy of the general population.
// >
pub fn question_5() -> char {
    todo!()
}

// TODO:
// > What are some ways to mitigate the risk of code exploits in blockchain
// > applications?
// >
// > - a) By allowing anyone to inspect the code.
// > - b) By using only professionally audited code.
// > - c) By implementing strict regulations on developers.
// >
pub fn question_6() -> char {
    todo!()
}

// TODO:
// > What event is an example of vulnerabilities in trusting code?
// >
// > - a) The Equifax data breach.
// > - b) The Cambridge Analytica scandal.
// > - c) The DAO attack.
// >
pub fn question_7() -> char {
    todo!()
}

// TODO:
// > In the context of Blockchain, what is a "chain split"?
// >
// > - a) A method for increasing transaction speed by processing parallel chains.
// > - b) A division of the community resulting in two competing versions
// >      of the blockchain.S
// > - c) A way to distribute mining rewards more fairly.
// >
pub fn question_8() -> char {
    todo!()
}

// TODO:
// > What is the relationship between Web 3.0's cryptographic guarantees and its
// > vulnerability to social engineering?
// >
// > - a) Cryptographic guarantees make Web 3.0 immune to social engineering.
// > - b) Web 3.0 may be more vulnerable to social engineering due to its complexity.
// > - c) Web 3.0 is equally as vulnerable to social engineering as Web 2.0.
// >
pub fn question_9() -> char {
    todo!()
}

// TODO:
// > What paradox can you highlight regarding the trustless nature of Web 3.0?
// >
// > - a) Trustless systems require more trust from users.
// > - b) The more trustless a system becomes, the less secure it is.
// > - c) While transactions are trustless, users still need to trust the developers
// >      who wrote the code.
// >
pub fn question_10() -> char {
    todo!()
}

// TODO:
// > Which is a way to address the issue of diverging opinions in blockchain
// > communities?
// >
// > - a) Exploring decentralized governance structures inspired by real-world
// >      solutions.
// > - b) Implementing centralized control mechanisms.
// > - c) Creating immutable rules that can never be changed
// >
pub fn question_11() -> char {
    todo!()
}
}

Checking your answers

  1. To make sure you haven't made any mistake in the format of your answers:
cargo test
  1. To make sure your answers are correct:
cargo test --features solutions