Talk:Egyptian division: Difference between revisions

m
Reverted edits by Thundergnat (talk) to last revision by Hout
m (Reverted edits by Thundergnat (talk) to last revision by Hout)
 
(2 intermediate revisions by 2 users not shown)
Line 48:
:P.S. Nigel, we tend not to sign examples on the task page, relying on the page history to track authorship. This also encourages others to correct errors they may spot etc. It's the wiki way on RC :-) --[[User:Paddy3118|Paddy3118]] ([[User talk:Paddy3118|talk]]) 20:13, 11 August 2017 (UTC)
:: How about just adding a simple 'extra credit' clause – 'Show that Egyptian division can be performed in your language without making any use of multiplication, division or exponentiation operators' [[User:Hout|Hout]] ([[User talk:Hout|talk]]) 21:55, 11 August 2017 (UTC)
 
==Haskell 'lazy lists' example==
 
Two thoughts about the current draft of this:
First, to avoid using (*) (in this exercise in deriving division from addition and subtraction), the function which you '''iterate''' for 'doubling' could either be <code Haskell>(+) >>= id</code> or the equivalent <code Haskell>join (+)</code> (where join is imported from Control.Monad).
Second, perhaps the task really needs a formulation which returns a remainder as well as a quotient ?
10,333

edits