1,381,932 research outputs found
Linear, bounded, functional pretty-printing
We present two implementations of Oppen's pretty-printing algorithm in Haskell that meet the efficiency of Oppen's imperative solution but have a simpler, clear structure. We start with an implementation that uses lazy evaluation to simulate two co-operating processes. Then we present an implementation that uses higher-order functions for delimited continuations to simulate co-routines with explicit scheduling
Pretty printing with lazy dequeues
There are several purely functional libraries for converting tree structured data into indented text, but they all make use of some backtracking. Over twenty years ago, Oppen published a more efficient imperative implementation of a pretty printer. This article shows that the same efficiency is also obtainable without destructive updates by developing a similar but purely functional Haskell implementation with the same complexity bounds. At its heart lie two lazy double ended queues
Green Exercise, Health and a Dose of Nature
A strong body of evidence now shows that exposure to nature has positive health and well-being benefits. Nature promotes stress recovery, protects from future stresses and improves concentration and ability to think clearly. It is also well established that regular physical activity has both physical and psychological health benefits. Therefore, knowing that both physical activity and nature independently enhance health, the term Green Exercise was coined to signify the synergistic health benefits derived from being active in green or natural places (Pretty et al., 2005)
Pretty War
Influenced by Farquar’s the Recruiting Office (1704), Pretty War is a participatory performance that employs a frivolous restoration backdrop to a horrible war. Restoration manners and army drill are taught in attempt to understand physical vocabularies beyond that of the civilian 21st century.
Pretty War is a Gareth White and Jane Munro project
Pretty Printing with Delimited Continuations
Pretty printing is the task of nicely formatting tree structured data within a given line width limit. In 1980 Oppen published a pretty printing algorithm that takes time linear in the size of the input, independent of the line width, and uses only limited look-ahead. This work inspired the development of a number of purely functional pretty printing libraries in Haskell. Here I present a new functional pretty printing algorithm that has all the nice properties of Oppen's and is surprisingly simple. A double-ended queue of delimited continuations is the key to addressing all aspects of the problem explicitly
FliPpr: A Prettier Invertible Printing System
When implementing a programming language, we often write
a parser and a pretty-printer. However, manually writing both programs
is not only tedious but also error-prone; it may happen that a pretty-printed
result is not correctly parsed. In this paper, we propose FliPpr,
which is a program transformation system that uses program inversion
to produce a CFG parser from a pretty-printer. This novel approach
has the advantages of fine-grained control over pretty-printing, and easy
reuse of existing efficient pretty-printer and parser implementations
Ghost sign for H. C. Pretty & Son Ltd. on New Bond Street, 2022.
Ghost sign for 'H.C. Pretty & Son Ltd.', reading 'Belting / Manufacturers, / Mill Furnishers / Head Office Church Gt'. This sign is not visible on Google Street View. Between 2010 and 2015, a window was added to the building, partially destroying the sign.
H.C. Pretty & Son Ltd. was founded in 1939 and dissolved in 2010
Ghost sign for H. C. Pretty & Son Ltd. on New Bond Street, 2010.
Ghost sign for 'H.C. Pretty & Son Ltd.', reading 'Belting / Manufacturers, / Mill Furnishers / Head Office Church Gt'. This sign is not visible on Google Street View. Between 2010 and 2015, a window was added to the building, partially destroying the sign.
H.C. Pretty & Son Ltd. was founded in 1939 and dissolved in 2010
Pretty Good Privacy
PGP ("Pretty Good Privacy") is a software package which provides security for private data transmitted over insecure media such as the internet. PGP is distinguished from other security packages by its ideal of decentralising trust away from institutional authorities, instead giving end-users of the software the right to decide who they trust and who they don't
- …
