CBCP Certified Blockchain Professional (CBCP) MCQ 4 — Questions and Answers
Question 1: In Solidity, what is the difference between 'storage' and 'memory' variable locations in smart contract execution?
- Storage is encrypted on-chain; memory is unencrypted during execution
- Storage persists permanently on-chain between calls; memory is temporary within a single call (Correct answer)
- Storage holds function parameters; memory holds state variables
- Storage is faster and cheaper; memory is slower and more expensive
Correct answer: Storage persists permanently on-chain between calls; memory is temporary within a single call
In Solidity, 'storage' variables are written to the blockchain and persist across transactions, while 'memory' variables exist only during a function call and are discarded afterward.
Question 2: What is the 'Oracle Problem' in smart contract design?
- Smart contracts cannot call Oracle database systems due to licensing restrictions
- Blockchains cannot natively access external real-world data without a trusted intermediary (Correct answer)
- Oracle nodes compete with miners for block rewards, creating congestion
- Smart contracts can only read Oracle data once per block due to consensus rules
Correct answer: Blockchains cannot natively access external real-world data without a trusted intermediary
The Oracle Problem describes the challenge that blockchains are deterministic closed systems unable to access real-world data natively, requiring external oracles that introduce trust assumptions.
Question 3: A DeFi protocol suffers a flash loan attack where an attacker borrows millions, manipulates an on-chain price oracle, and profits instantly. What is the root cause?
- Inadequate transaction fee incentives for validators
- Reliance on a single on-chain DEX spot price as an oracle without time-weighting (Correct answer)
- Smart contract code compiled with an outdated Solidity version
- Insufficient block gas limit preventing liquidation transactions
Correct answer: Reliance on a single on-chain DEX spot price as an oracle without time-weighting
Flash loan attacks typically exploit spot-price oracles drawn from a single DEX, which an attacker can manipulate within one transaction block; time-weighted average prices (TWAPs) mitigate this.
Question 4: Which property ensures that a blockchain transaction, once confirmed in sufficient blocks, cannot be reversed by any single party?
- Transparency
- Decentralization
- Finality (Correct answer)
- Pseudonymity
Correct answer: Finality
Finality (probabilistic or absolute depending on consensus mechanism) is the property ensuring a confirmed transaction cannot be rolled back, providing settlement certainty to participants.
Question 5: In enterprise blockchain governance, what is a 'permissioned' network's primary advantage over a public blockchain for regulated industries?
- Permissioned networks are always faster due to fewer nodes
- Permissioned networks allow known, vetted identities and regulatory compliance controls (Correct answer)
- Permissioned networks eliminate the need for consensus mechanisms entirely
- Permissioned networks have lower hardware requirements for node operation
Correct answer: Permissioned networks allow known, vetted identities and regulatory compliance controls
Permissioned blockchains restrict participation to vetted entities, enabling KYC/AML compliance, auditability by regulators, and governance controls required in finance, healthcare, and supply chain.
Question 6: What does the CAP theorem imply for distributed blockchain systems during a network partition?
- Blockchains must choose between consistency and availability when partitioned (Correct answer)
- Blockchains achieve all three CAP properties simultaneously through cryptography
- CAP theorem only applies to traditional databases, not blockchains
- Network partitions are impossible in PoW systems due to mining incentives
Correct answer: Blockchains must choose between consistency and availability when partitioned
CAP theorem states a distributed system can only guarantee two of Consistency, Availability, and Partition Tolerance; during a partition, most blockchains prioritize consistency (refusing to fork) or availability (allowing temporary forks).
Question 7: Which tokenization model represents fractional ownership of a real-world asset such as real estate on a blockchain?
- Utility Token
- Security Token (STO) (Correct answer)
- Stablecoin
- Non-Fungible Token (NFT)
Correct answer: Security Token (STO)
Security Tokens represent ownership stakes or financial rights in real-world assets and are subject to securities regulations, making them the appropriate model for tokenized real estate or equity.
In Solidity, what is the difference between 'storage' and 'memory' variable locations in smart contract execution?