计算机科学 > 程序设计语言
[提交于 2018年7月31日]
标题:Computing Integer Sequences: Filtering vs Generation (Functional Pearl)
查看原文 PDF 中文 PDF (下批处理) EasyResearch 阅读摘要:As a report of a teaching experience, we analyse Haskell programs computing two integer sequences: the Hamming sequence and the Ulam sequence. For both of them, we investigate two strategies of computation: the first is based on filtering out those natural numbers that do not belong to the sequence, whereas the second is based on the direct generation of num- bers that belong to the sequence. Advocating cross-fertilisation among ideas emerging when programming in different programming paradigms, in the background, we sketch out some considerations about corresponding C programs solving the same two problems.
提交历史
来自:Ivano Salvo[v1] 2018年7月31日 星期二 12:46:13 UTC