OK, here's the question:
Give a DCG that generates the set of strings w?{0,1}* with the same number of 0's as 1's so that, for example
?- s([0,1,1,0],[]).
yes
?- s([0,0,1,1,],[]).
yes
?- s([1,1,0,1,0],[]).
no
Now, my program is this:
s--> [].
s--> z,s,o,s.
s--> o,s,z,s.
z--> [0].
o-->...