Susumu Katayama
Sep. 24, 2013
on-line dictionaries for Haskell libraries
(Flash Fill of Excel 2013)
Feel free to try it from your PC / smart phone!
pure total functions only. IO ⊥
Prelude
, Data.List
, Data.Char
, Data.Maybe
Float
Double
Integer
problems | MagicHaskeller | Flash Fill |
---|---|---|
99 Haskell Problems | 11/20 (55%) | 3/20 (15%) |
Flash Fill Examples | 3/10 (30%) | 9/10 (90%) |
Flash Fill is quite specialized
DSL
limited use of conditionals
powerful regexp, but
can only deal with strings. no arithmetic
Haskell program synthesis by examples
Sometimes works, sometimes not.
Supposed to be useful for casual programming
Generate-and-test approach with shared memo table
Lots of room for efficiency/usability improvements
MagicExceller (?)
The idea of shared memo table might be applied to Agda proof search.
Regrettably I did not check 2013 Programming Contest.
for not cracking the server so far!
Problem 7: Flatten a nested list structure. Could not make a query (no support of creating new data types)
Problem 8: Eliminate consecutive duplicates of list elements. Problem 9: Pack consecutive duplicates of list elements into sublists. Problem 10: Run-length encoding of a list.Problem 11 - 13: Could not make a query (no support of creating new data types)
Problem 14: Duplicate the elements of a list. Problem 15: Replicate the elements of a list a given number of times. Problem 16: Drop every N'th element from a list. Problem 17: Split a list into two parts; the length of the first part is given. Problem 18: Extract a slice from a list. Problem 19: Rotate a list N places to the left. Problem 20: Remove the K'th element from a list.problem | MagH result | Flash Fill result |
---|---|---|
Problem 1 | O | O |
Problem 2 | O | O |
Problem 3 | O | X |
Problem 4 | Otr | X |
Problem 5 | Otr | X |
Problem 6 | O | X |
Problem 7 | Xdata | Xdata |
Problem 8 | O | X |
Problem 9 | Otr | X |
Problem 10 | X | X |
Problem 11 | Xdata | Xdata |
Problem 12 | Xdata | Xdata |
Problem 13 | Xdata | Xdata |
Problem 14 | O | O |
Problem 15 | O | X |
Problem 16 | X | X |
Problem 17 | X | X |
Problem 18 | O | X |
Problem 19 | X | X |
Problem 20 | X | X |
problem | MagH result | Flash Fill result |
---|---|---|
Example 1 | X | O |
Example 2 | O | O |
Example 3 | X | O |
Example 4 | O | O |
Example 5 | X | O |
Example 6 | O | O |
Example 7 | X | O |
Example 8 | X | X |
Example 9 | X | O |
Example 10 | X | O |