Bird
Raised Fist0

Consider a system with states: Locked and Unlocked. The event InsertCoin moves it from Locked to Unlocked. What is the next state after InsertCoin if the system is currently Locked?

medium📝 Predict Output Q13 of Q15
Testing Fundamentals - Functional Testing Techniques
Consider a system with states: Locked and Unlocked. The event InsertCoin moves it from Locked to Unlocked. What is the next state after InsertCoin if the system is currently Locked?
ALocked
BUnlocked
CError
DUnknown
Step-by-Step Solution
Solution:
  1. Step 1: Identify current state and event

    The system is currently in the Locked state, and the event InsertCoin occurs.
  2. Step 2: Apply the state transition rule

    According to the rule, InsertCoin moves the system from Locked to Unlocked state.
  3. Final Answer:

    Unlocked -> Option B
  4. Quick Check:

    Locked + InsertCoin = Unlocked [OK]
Quick Trick: Follow event rules from current state [OK]
Common Mistakes:
MISTAKES
  • Assuming state stays the same after event
  • Choosing error or unknown without reason
  • Ignoring the given transition rule

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Testing Fundamentals Quizzes