Cody

Problem 2677. Find out next state (NS) of T Flip-Flop.

Solution 2432839

Submitted on 31 May 2020 by Nikolaos Nikolaou
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Pass
Q_PS=0; T=0; y_correct = 0; assert(isequal(T_FF(Q_PS,T),y_correct))

t = 0 0 Table = 0 0 1 0 0 1 1 1 NS = 0 1 1 0 Q_NS = 0

2   Pass
Q_PS=1; T=0; y_correct = 1; assert(isequal(T_FF(Q_PS,T),y_correct))

t = 1 0 Table = 0 0 1 0 0 1 1 1 NS = 0 1 1 0 Q_NS = 1

3   Pass
Q_PS=0; T=1; y_correct = 1; assert(isequal(T_FF(Q_PS,T),y_correct))

t = 0 1 Table = 0 0 1 0 0 1 1 1 NS = 0 1 1 0 Q_NS = 1

4   Pass
Q_PS=1; T=1; y_correct = 0; assert(isequal(T_FF(Q_PS,T),y_correct))

t = 1 1 Table = 0 0 1 0 0 1 1 1 NS = 0 1 1 0 Q_NS = 0

Suggested Problems

More from this Author70

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!