Explore BrainMass

Explore BrainMass

    Theory of Computation with a Vending Machine

    Not what you're looking for? Search our solutions OR ask your own Custom question.

    This content was COPIED from BrainMass.com - View the original, and get the already-completed solution here!

    Problem: Consider a vending machine that accepts nickels, dimes and quarters.
    1. Give an implicit definition of the set of all strings whose value mod 30 = 0.
    2. Give recursive definition of the set of all strings whose value = 30 cents.

    See attachment for the full and formatted problem.

    © BrainMass Inc. brainmass.com November 24, 2022, 11:45 am ad1c9bdddf


    Solution Preview

    Please see attached file.


    = { str | (str ε C* ) ∧ ( (value(str) mod 30 ) = 0 ) }

    2. Let describe the set of all strings whose sum is 30.
    Basis case: nnnnn ∈ ,
    nq ∈ and qn ∈ ...

    Solution Summary

    The solution is given in a clearly-formatted word document.