equal
deleted
inserted
replaced
106 case (r1s, r2s) => SEQ(r1s, r2s) |
106 case (r1s, r2s) => SEQ(r1s, r2s) |
107 } |
107 } |
108 case r => r |
108 case r => r |
109 } |
109 } |
110 |
110 |
|
111 simp(ALT(ONE | CHAR('a'), CHAR('a') | ONE)) |
111 |
112 |
112 // (4) Complete the two functions below; the first |
113 // (4) Complete the two functions below; the first |
113 // calculates the derivative w.r.t. a string; the second |
114 // calculates the derivative w.r.t. a string; the second |
114 // is the regular expression matcher taking a regular |
115 // is the regular expression matcher taking a regular |
115 // expression and a string and checks whether the |
116 // expression and a string and checks whether the |