Review of “Algorithms for Functional Programming” by John David Stone, Springer-Verlag, 2018
Notice bibliographique
Résumé
Many textbooks start out as informal notes for university courses, refined through repeated offerings.The book under review came out of the author's experiences as a lecturer at an American liberal-arts college, Grinnell, where the first course in computation used Scheme for many years.The first chapter, "Essential Notations", rapidly introduces many features of R7RS Scheme and its libraries, augmented by some primitives written by the author.The next chapter, "The Tool Box", presents or builds a host of abstractions, such as couplers, adapters, and recursion managers (e.g., folds), which are used extensively in the rest of the text.The ambition of this book can be seen in the topic lists for the next two chapters."Data Structures" covers lists, sources (streams without caching, which would necessitate mutation), trees, bushes (rose trees), bags, sets, tables, and buffers (queues), all implemented mostly using pairs and lists (occasionally records)."Sorting" covers insertion sort, selection sort, quicksort, mergesort, binary search trees, treesort, red-black trees (both insertion and deletion), pairing heaps, and order statistics.Considering that the word "Algorithms" is in the title, the book is surprisingly shy about discussing efficiency.Linear time appears briefly; the phrase "proportional to" is used a few times, and "logarithm" only once, in reference to running times.I understand the reluctance; order notation and the proper use of recurrences for analysis of running time are nettles that one hesitates to grasp.They can be avoided in a first course, but only barely, and without them, the motivation for many of these more advanced topics becomes much more difficult.The next chapter, "Combinatorial Constructions", is possibly the most successful, perhaps because it is rich with helper functions and examples, and topics not usually covered: Cartesian products, subsequences and selections (subsets and combinations, but of an ordered list), and finally permutations and partitions, all with ranking and unranking (going from a numerical index to an element of the full answer and vice versa).In the last two chapters, the author's principled insistence on purity and layers of abstraction is at odds with the material."Graphs" presents depth-first and breadth-first traversal, spanning trees, shortest paths (Bellman-Ford, Dijkstra, and Floyd-Warshall), and maximum flow (Ford-Fulkerson)."Sublist Search" is chiefly concerned with Knuth-Morris-Pratt and Boyer-Moore string search.These are topics for which pure functional programming does not have a good story.One should be willing to sacrifice efficiency for
Récupéré en direct depuis OpenAlex et désinversé. Les résumés ne sont pas conservés dans cette base de données : les index inversés représentent 8,6 Go des 9,3 Go de texte de la base, et le serveur dispose de 13 Go libres.
Comment cette classification a été obtenuedéplier
Prédiction machine sur la base complète
Imitation des enseignantsNi prévalence calibrée, ni vérité terrain. Validation humaine à venir. Le volet Gemma est une étiquette directe du modèle pour chaque travail de la base, lue sur la notice réduite au titre. Le volet Codex est un classifieur appris des 10 348 étiquettes directes de Codex et calibré sur les taux pondérés de l'échantillon; les champs sans appui suffisant ne portent aucun appel Codex. Le mode candidate est l'union des deux volets; le consensus est leur intersection. Ces sorties portent le statut machine_predicted_unvalidated et ne sont pas des étiquettes humaines.
Scores du classifieur distillé par catégorie (deux têtes)
| Catégorie | Codex | Gemma |
|---|---|---|
| Métarecherche | 0,003 | 0,009 |
| Méta-épidémiologie (sens strict) | 0,002 | 0,001 |
| Méta-épidémiologie (sens large) | 0,001 | 0,001 |
| Bibliométrie | 0,003 | 0,004 |
| Études des sciences et des technologies | 0,001 | 0,003 |
| Communication savante | 0,002 | 0,005 |
| Science ouverte | 0,002 | 0,001 |
| Intégrité de la recherche | 0,002 | 0,005 |
| Charge utile insuffisante (le modèle a refusé de juger) | 0,013 | 0,011 |
Scores machine (provisoires)
Les deux têtes enseignantes du modèle étudiant, lues sur ce travail. Un score ordonne la base pour la relecture; il n'affirme jamais une catégorie, et le statut de validation accompagne chaque rangée tel quel.
Scores de référence d'un modèle non mature (critères de maturité non atteints, 7 itérations). Un score ordonne; il n'affirme jamais une catégorie.
score_only:v0-immature-baseline · tel quel depuis la passe de notation : score_only signifie que le nombre peut ordonner les travaux, et qu'aucune étiquette de catégorie n'en découleClassification
machine, non validéePrédiction automatique; un appel candidat d’une seule source (Gemma direct ou Codex distillé), pas un consensus.
Le détail, modèle par modèle et score par score, se trouve en fin de page sous « Comment cette classification a été obtenue ».