5 citations · 11 across the 7 of their papers we have counts for
6 papers · 1 filter
Deriving monadic quicksort (Declarative Pearl)
Shin-Cheng Mu, Tsung-Ju Chiang
To demonstrate derivation of monadic programs, we present a specification of sorting using the non-determinism monad, and derive pure quicksort on lists and state-monadic quicksort…
A greedy algorithm for dropping digits (Functional Pearl)
Richard Bird, Shin-Cheng Mu
Consider the puzzle: given a number, remove digits such that the resulting number is as large as possible. Various techniques were employed to derive a linear-time solution to…
Calculating a backtracking algorithm: an exercise in monadic program derivation
Shin-Cheng Mu
Equational reasoning is among the most important tools that functional programming provides us. Curiously, relatively less attention has been paid to reasoning about monadic progra…
Equational reasoning for non-determinism monad: the case of Spark aggregation
Shin-Cheng Mu
As part of the author's studies on equational reasoning for monadic programs, this report focus on non-determinism monad. We discuss what properties this monad should satisfy, what…
Longest segment of balanced parentheses -- an exercise in program inversion in a segment problem (Functional Pearl)
Shin-Cheng Mu, Tsung-Ju Chiang
Given a string of parentheses, the task is to find the longest consecutive segment that is balanced, in linear time. We find this problem interesting because it involves a combinat…
Type Safe Redis Queries: A Case Study of Type-Level Programming in Haskell
Ting-Yan Lai, Tyng-Ruey Chuang, Shin-Cheng Mu
Redis is an in-memory data structure store, often used as a database, with a Haskell interface Hedis. Redis is dynamically typed --- a key can be discarded and re-associated to a v…