You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
beautiful-racket/beautiful-racket-ragg/br/ragg/examples/01-equal.rkt

13 lines
189 B
Racket

9 years ago
#lang br/ragg
## Equal numbers of 0 and 1s in a string.
##
## (Thanks to mithos28 for this one.)
equal : [zero one | one zero]
zero : "0" equal | equal "0"
one : "1" equal | equal "1"