2 Saved paren in alternative.

f s=sum[1|c<-s,_<-['a'..c]]==100


Try it online!

The idea is to make a list of characters from a to the given character for each character in the list, and check that the total length is 100.

Other attempts:

f s=sum[1|c<-s,_<-['a'..c]]==100

f s=100==length((\c->['a'..c])=<<s)
(==100).length.(>>=( \c->['a'..c]))
(==100).length.(=<<)(\c->['a'..c])
(==100).length.(enumFromTo 'a'=<<)
f s=100==length(do c<-s;['a'..c])


Too bad enumFromTo is so long.

f s=sum[1|c<-s,_<-['a'..c]]==100


Try it online!

The idea is to make a list of characters from a to the given character for each character in the list, and check that the total length is 100.

Other attempts:

f s=sum[1|c<-s,_<-['a'..c]]==100

f s=100==length((\c->['a'..c])=<<s)
(==100).length.(>>=(\c->['a'..c]))
(==100).length.(=<<)(\c->['a'..c])
(==100).length.(enumFromTo 'a'=<<)
f s=100==length(do c<-s;['a'..c])


Too bad enumFromTo is so long.

f s=sum[1|c<-s,_<-['a'..c]]==100


Try it online!

The idea is to make a list of characters from a to the given character for each character in the list, and check that the total length is 100.

Other attempts:

f s=sum[1|c<-s,_<-['a'..c]]==100

f s=100==length((\c->['a'..c])=<<s)
(==100).length.(>>= \c->['a'..c])
(==100).length.(=<<)(\c->['a'..c])
(==100).length.(enumFromTo 'a'=<<)
f s=100==length(do c<-s;['a'..c])


Too bad enumFromTo is so long.

1

f s=sum[1|c<-s,_<-['a'..c]]==100


Try it online!

The idea is to make a list of characters from a to the given character for each character in the list, and check that the total length is 100.

Other attempts:

f s=sum[1|c<-s,_<-['a'..c]]==100


Too bad enumFromTo is so long.