about summary refs log tree commit diff
path: root/day5.k
diff options
context:
space:
mode:
Diffstat (limited to 'day5.k')
-rw-r--r--day5.k3
1 files changed, 1 insertions, 2 deletions
diff --git a/day5.k b/day5.k
index 938d43c..09fef93 100644
--- a/day5.k
+++ b/day5.k
@@ -7,9 +7,8 @@ r3: {~#,/x _ss ("ab";"cd";"pq";"xy")}; / no ab/cd/pq/xy
 #&(r3'd)&(r2'd)&(r1'd)
 
 bg: {[s]{x;2#(x-1) _ s}'1+!#s}; / bigrams
-u: {x@*:'=x}; / uniq
 
-r4: {0<#&1<#:' x _ss u@bg x}; / duplicate bigram
+r4: {0<#&1<#:' x _ss ?bg x}; / duplicate bigram
 r5: {0<#&(-2_ x)=(2_ x)}; / matches (.).\1
 
 #&(r4'd)&(r5'd)