0% found this document useful (0 votes)
200 views17 pages

Web 3

Uploaded by

xfactor8056
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
200 views17 pages

Web 3

Uploaded by

xfactor8056
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 17

Web3 Cohort by 100xDevs

Goal
To create a Cohort of people who are great at Blockchains, Web3.

My background in Web3
Detailed video -

Started working in Sept 2022. Worked at ~3 companies since. Primarily worked at Wallets,
Exchanges and Gambling websites.

Easy -

Hard -

1. - Harkirat Singh
2. - Led by @cb7chaitanya, mentored by Harkirat

If you want to propose a project, please build a v1 for the Superteam hackathon and we can
sponsor it further
6. RPC aggregator - Let a user put in a bunch of RPCs from various providers (Helius, Alchemy,
QuickNode) and you should figure out which one to forward requests to (Similar to
)

7. Wallet adapter for a web based wallet - ‣

8. Youtube channel opinions market - Let people trade on a coin associated to a Youtube
channel. Creator can come and collect royalties by connecting their YT account.

9. Tiplink (even tho we’re building it saparately, if you want to build a better version with a twist,
you should do it)

10. Github Bounty Dispenser. Make users give their Adhar/Pan. Make users link their github with
their wallet address. Allow maintainers to approve bounties. Create a dashboard where you
can track profiles of users/companies and a leaderboard of contributors based on bounty
earned

11. UI Library for Solana - NFTCard, TokenCard, SwapCard


DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

Fractional reserve Banking


Banks dont have your money. They lend out most of it.
If there is a bank run (everyone goes to the bank to withdraw their money), banks wont be able
to pay everyone

4 of 17 02-08-2024, 20:46
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

Silicon valley collapsed in 2022. I was in the US when it happened. Most YC companies had their
funds in SVB. They were bailed out, but if not, you would’ve seen a lot of startups die.

Bailouts
The 2008 Financial crisis was triggered by a financial instrument called mortgage-backed
securities.
Even though the banks at Wall Street were at fault, the government ended up bailing them out
using Taxpayer money.

5 of 17 02-08-2024, 20:46
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

INR Depreciation (even worse in countries like Japan)


1. USD

1. JPY

Currencies are not backed by assets anymore

6 of 17 02-08-2024, 20:46
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

How to create a new currency?


Right now, currencies can only be issued by central governments. You can’t create your own
Kirat coin and ask users to use it.

Even if I do issue a Kirat coin , no one would use it, and for good reasons -

1. I can print any number of Kirat coins, making myself richer

2. I become the central mint and verification athority for the coin.

3. No one would (or should) trust me

7 of 17 02-08-2024, 20:46
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

Intro to hashing

Hashing is a process that transforms input data (of any size) into a fixed-size string of characters.

Hash functions have several important properties:

1. Deterministic: The same input will always produce the same output.

2. Fast computation: The hash value can be quickly computed for any given data.

8 of 17 02-08-2024, 20:46
3. Pre-image resistance: It should be computationally infeasible to reverse the hash function
(i.e., find the original input given its hash output).

4. Small changes in input produce large changes in output: Even a tiny change in the input
should drastically change the hash output.

5. Collision resistance: It should be computationally infeasible to find two different inputs that
produce the same hash output.

Is this a hashing algorithm?


What if I try “hashing” a string by increasing each alphabet’s value by one. Do you think this
follows all the rules we’ve written above?

SHA-256
Lets try out a famous hash function, SHA-256 here -
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

Node.js code for generating SHA-256

const crypto = require('crypto'); Copy

const input = "100xdevs";


const hash = crypto.createHash('sha256').update(input).digest('hex');

console.log(hash)

10 of 17 02-08-2024, 20:46
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

Intro to Proof of work

Assignment #1
What if I ask you the following question — Give me an input string that outputs a SHA-256 hash
that starts with 00000 . How will you do it?

A: You will have to brute force until you find a value that starts with 00000
Node.js code

const crypto = require('crypto'); Copy

// Function to find an input string that produces a hash starting with '00000'
function findHashWithPrefix(prefix) {
let input = 0;
while (true) {
let inputStr = input.toString();
let hash = crypto.createHash('sha256').update(inputStr).digest
if (hash.startsWith(prefix)) {
return { input: inputStr, hash: hash };
}
input++;
}
}

// Find and print the input string and hash


const result = findHashWithPrefix('00000');
console.log(`Input: ${result.input}`);
console.log(`Hash: ${result.hash}`);

11 of 17 02-08-2024, 20:46
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

Assignment #2
What if I ask you that the input string should start with 100xdevs ? How would the code
change?
Node.js code

const crypto = require('crypto'); Copy

// Function to find an input string that produces a hash starting with '00000'
function findHashWithPrefix(prefix) {
let input = 0;
while (true) {
let inputStr = "100xdevs" + input.toString();
let hash = crypto.createHash('sha256').update(inputStr).digest
if (hash.startsWith(prefix)) {
return { input: inputStr, hash: hash };
}
input++;
}
}

// Find and print the input string and hash


const result = findHashWithPrefix('00000');
console.log(`Input: ${result.input}`);
console.log(`Hash: ${result.hash}`);

12 of 17 02-08-2024, 20:46
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

Assignment #3
What if I ask you to find a nonce for the following input -

harkirat => Raman | Rs 100 Copy


Ram => Ankit | Rs 10

Node.js code

const crypto = require('crypto'); Copy

// Function to find an input string that produces a hash starting with '00000'
function findHashWithPrefix(prefix) {
let input = 0;
while (true) {
let inputStr = `
harkirat => Raman | Rs 100
Ram => Ankit | Rs 10
` + input.toString();
let hash = crypto.createHash('sha256').update(inputStr).digest
if (hash.startsWith(prefix)) {
return { input: inputStr, hash: hash };
}
input++;
}
}

// Find and print the input string and hash


const result = findHashWithPrefix('00000');
console.log(`Input: ${result.input}`);
console.log(`Hash: ${result.hash}`);

13 of 17 02-08-2024, 20:46
Assignment #4
Lets explore
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

3. Timestamp server

4. Proof of work

15 of 17 02-08-2024, 20:46
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

5. Network

6. Incentive

16 of 17 02-08-2024, 20:46
DailyCode https://projects.100xdevs.com/pdf/web3-orientation/Web3-Cohort---Ori...

17 of 17 02-08-2024, 20:46

You might also like