NPTEL Blockchain and its Applications Week 5 Assignment Answers 2024
1. The height of the block is the _________ in the chain between it and the genesis block.
a. Metafiles
b. Hash
c. Log size
d. Number of blocks
✅ Answer: d. Number of blocks
📘 Explanation: Block height represents the number of blocks in the chain between the current block and the genesis block.
2. What is the CLI command used to send ethers after the nodes have been initialized?
a. eth.submitTransaction()
b. eth.sendTransaction()
c. eth.sendIBANTransaction()
d. eth.sendRawTransaction()
✅ Answer: b. eth.sendTransaction()
📘 Explanation: eth.sendTransaction() is a standard command in the Ethereum JavaScript console to send ether between accounts.
3. Which of the following syntax is correct to write data in a smart contract using Solidity?
a. myContract.methods.store(“55”).set()
b. myContract.methods.write(“55”).send()
c. myContract.methods.store(“55”).send()
d. myContract.methods.write(“55”).set()
✅ Answer: c. myContract.methods.store(“55”).send()
📘 Explanation: In web3.js, .methods.store().send() is the correct syntax to invoke a write function in the smart contract.
4. What is the limitation of using the consensus algorithm Proof of Work (PoW)?
a. A lot of mining power is wasted as only one gets success in mining at a time
b. PoW is used for permissioned blockchain
c. It is used for blockchain mining
d. High transaction throughput
✅ Answer: a. A lot of mining power is wasted as only one gets success in mining at a time
📘 Explanation: PoW is energy-intensive and inefficient as many nodes work but only one wins to mine the block.
5. Which statement(s) is/are true for PoS (Proof of Stake) consensus?
a. Depends on the work done by the miner
b. Depends on the amount of cryptocurrency the miner holds
c. Provides less protection in general
d. None of the above
✅ Answer: b. Depends on the amount of cryptocurrency the miner holds
📘 Explanation: In PoS, the chances of validating a block depend on the amount of stake (crypto) a validator holds.
6. Which of the following is/are applicable for PoET (Proof of Elapsed Time) consensus?
a. Each participant in the blockchain network waits a random amount of time
b. The first participant to finish becomes the follower for the new block
c. Trusted execution platform and attestation are used to verify that the proposer has really waited
d. The first participant to finish becomes the leader for the new block
✅ Answer: a, c, d
📘 Explanation: PoET uses a trusted execution environment (like Intel SGX) to ensure a random wait time and fairness.
7. Proof of Burn consensus algorithms also consider virtual resources or digital coins for participating in the mining activity?
a. True
b. False
✅ Answer: a. True
📘 Explanation: In Proof of Burn, miners burn (destroy) coins to get mining rights, treating coins as a resource.
8. 15 ether equals:
a. 15 × (10^16) wei
b. 15 × (10^18) wei
c. 15 × (10^6) wei
d. 15 × (10^8) wei
✅ Answer: b. 15 × (10^18) wei
📘 Explanation: 1 ether = 10^18 wei. So 15 ether = 15 × 10^18 wei.
9. How can an attacker manipulate the transaction history of an existing blockchain?
a. The attacker hard-forked the network and created a new blockchain network.
b. The attacker modified the smart contract and recovered the investor’s money.
c. The attacker gained control of more than 51% of the network’s computing power.
d. The attacker gained control of less than 49% of the network’s computing power.
✅ Answer: c. The attacker gained control of more than 51% of the network’s computing power.
📘 Explanation: A 51% attack allows an attacker to reverse transactions and double-spend.
10. What library/API is used for smart contract deployment and invocation from Dapp?
a. Contract
b. web3
c. admin
d. eth
✅ Answer: b. web3
📘 Explanation: web3.js is the JavaScript library used to interact with Ethereum blockchain from DApps.


