Skip to content

Commit e3e8336

Browse files
committed
feat: pt 3 quiz
1 parent 987f8c9 commit e3e8336

File tree

2 files changed

+181
-10
lines changed

2 files changed

+181
-10
lines changed

src/pages/lessons/fundamentals/3.mdx

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,6 @@ contract Billboard {
6969
}
7070
}
7171
```
72-
Billboard: a basic Solidity contract that sets and stores a single message
7372

7473
If you're familiar with object-oriented programming, a contract will look an awful lot like the concept of a class. In effect, when a contract is deployed, a single instance becomes available for all the world to use — analogous to a "singleton" class.
7574

@@ -85,7 +84,7 @@ Earlier in this blog series, you may recall reading that the only way to make ch
8584

8685
While a contract is being written, developers will frequently compile their code for manual or automated testing. The output of each compilation is the contract's **bytecode**.
8786

88-
To deploy a contract, one needs only to send a transaction with that contract's bytecode in the data field of the transaction and omit the to address. The EVM will take care of the rest. Once the transaction has been included in a block, the transaction receipt contains the deployed contract's address where it can be interacted with.
87+
To deploy a contract, one needs only to send a transaction with that contract's bytecode in the `data` field of the transaction and omit the `to` address. The EVM will take care of the rest. Once the transaction has been included in a block, the transaction receipt contains the deployed contract's address where it can be interacted with.
8988

9089
```python
9190
tx = {
@@ -97,7 +96,6 @@ tx = {
9796
w3.eth.send_transaction(tx)
9897
```
9998

100-
10199
Tools like web3.py offer slightly more human-friendly ways to go about this. One of the other outputs of a compilation is the contract's ABI, and some additional metadata.
102100

103101
<Callout emoji="💡" size="md" variant="info">
@@ -131,8 +129,6 @@ billboard.functions.writeBillboard("sneks everywhere").transact()
131129
billboard.functions.message().call()
132130
# sneks everywhere
133131
```
134-
Example contract deployment and interaction via web3.py
135-
136132

137133
## How far can a contract go?
138134

@@ -196,11 +192,9 @@ When you're ready for them, there are a range of smart contract development fram
196192
## And breathe
197193

198194
We covered a lot of ground! Did all that sink in? Test yourself:
199-
- What are smart contracts?
200-
- What's a dapp?
201-
- How do public smart contracts influence business models?
202-
- How are smart contracts deployed?
203-
- How do you interact with a smart contract?
195+
196+
<br />
197+
<QuizStatusChecker quiz="quiz-eth-intro-3" />
204198

205199
If you're satisfied with your answers, you've now got a strong foundation on which to begin your dapp-building journey. Use the resources recommended above to take your next steps and be sure to document your own journey! Many of the tools in this industry are brand new or rapidly evolving. A great way to make a positive impact is simply to help improve the documentation of each tool as you find opportunities to.
206200

Lines changed: 177 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,177 @@
1+
{
2+
"title": "Quiz: Intro to Ethereum, Pt. 3",
3+
"questions": [
4+
{
5+
"question": "What is a smart contract?",
6+
"options": [
7+
{
8+
"answer": "A performant database"
9+
},
10+
{
11+
"answer": "A computer program that is deployed on a blockchain",
12+
"correct": true
13+
},
14+
{
15+
"answer": "Code that is guaranteed to have no vulnerabilities"
16+
}
17+
]
18+
},
19+
{
20+
"question": "What can a smart contract do?",
21+
"options": [
22+
{
23+
"answer": "Send and receive ether",
24+
"correct": true
25+
},
26+
{
27+
"answer": "Deploy other smart contracts",
28+
"correct": true
29+
},
30+
{
31+
"answer": "Interact with other smart contracts",
32+
"correct": true
33+
},
34+
{
35+
"answer": "Maintain internal state",
36+
"correct": true
37+
}
38+
]
39+
},
40+
{
41+
"question": "Before entrusting a contract with nontrivial assets, you should:",
42+
"options": [
43+
{
44+
"answer": "Check for verified source code",
45+
"correct": true
46+
},
47+
{
48+
"answer": "Write and deploy your own version of the contract"
49+
},
50+
{
51+
"answer": "Memorize the contract's bytecode"
52+
},
53+
{
54+
"answer": "Check for a contract's audit report",
55+
"correct": true
56+
}
57+
]
58+
},
59+
{
60+
"question": "You can build apps that rely on externally created smart contracts",
61+
"options": [
62+
{
63+
"answer": "True",
64+
"correct": true
65+
},
66+
{
67+
"answer": "False"
68+
}
69+
]
70+
},
71+
{
72+
"question": "Before you fork someone's project to build your own, you should:",
73+
"options": [
74+
{
75+
"answer": "Read and respect the software license",
76+
"correct": true
77+
},
78+
{
79+
"answer": "Credit the original authors where appropriate",
80+
"correct": true
81+
},
82+
{
83+
"answer": "Pretend it was all your idea"
84+
}
85+
]
86+
},
87+
{
88+
"question": "Ethereum smart contract languages include:",
89+
"options": [
90+
{
91+
"answer": "Vyper",
92+
"correct": true
93+
},
94+
{
95+
"answer": "EVM"
96+
},
97+
{
98+
"answer": "Fe",
99+
"correct": true
100+
},
101+
{
102+
"answer": "Solidity",
103+
"correct": true
104+
}
105+
]
106+
},
107+
{
108+
"question": "For all users, a smart contract has the same state.",
109+
"options": [
110+
{
111+
"answer": "True",
112+
"correct": true
113+
},
114+
{
115+
"answer": "False"
116+
}
117+
]
118+
},
119+
{
120+
"question": "What does ABI stand for?",
121+
"options": [
122+
{
123+
"answer": "Average Binary Implementation"
124+
},
125+
{
126+
"answer": "Approximate Beverage Intake"
127+
},
128+
{
129+
"answer": "Alternate Bovine Intervention"
130+
},
131+
{
132+
"answer": "Application Binary Interface",
133+
"correct": true
134+
}
135+
]
136+
},
137+
{
138+
"question": "What is an ABI?",
139+
"options": [
140+
{
141+
"answer": "A machine-readable description of a contract's functions, events, and data types",
142+
"correct": true
143+
},
144+
{
145+
"answer": "The compiled and optimized contract bytecode"
146+
},
147+
{
148+
"answer": "A convention for auditing smart contracts"
149+
}
150+
]
151+
},
152+
{
153+
"question": "Using established token standards can make your app widely compatible with Ethereum assets and wallets.",
154+
"options": [
155+
{
156+
"answer": "True",
157+
"correct": true
158+
},
159+
{
160+
"answer": "False"
161+
}
162+
]
163+
},
164+
{
165+
"question": "Once a contract is deployed, it is impossible to upgrade it.",
166+
"options": [
167+
{
168+
"answer": "True"
169+
},
170+
{
171+
"answer": "False",
172+
"correct": true
173+
}
174+
]
175+
}
176+
]
177+
}

0 commit comments

Comments
 (0)