Home › Practice › RTL Design › 4-bit one-hot validator
4-bit one-hot validator
EasyRTLcombinationalcodes
Check whether a 4-bit bus carries a valid one-hot code.
validis1when exactly one bit ofdis1(4'b0001,4'b0010,4'b0100, or4'b1000).validis0whendis all zeros or has two or more1bits.- No clock.
No install and no sign-up needed. You write your answer in the editor and Nishkam checks it.