Design a synchronous binary 3-bit up/down counter using JK flip-flops, your counter must have an input D, such that D=0 makes the counter count up and D=1 makes the counter count down as shown below
Count sequence for D=0
0,1,2,3,4,5,6,7,0,........
Count sequence for D=1
7,6,5,4,3,2,1,0,7........