Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
winitzki committed Oct 14, 2024
1 parent d6aa041 commit 22baef5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion tutorial/Float/add.dhall
Original file line number Diff line number Diff line change
Expand Up @@ -542,7 +542,7 @@ let _ = assert : checkAddShow -12345678 -8 +123 -2 5 "+1.10655"

let _ = assert : checkAddShow -12345678 -8 +123 -2 9 "+1.10654322"

in { --Float/add,
in { Float/add,
addOrSubtractUnsignedAIsGreater
, subtractUnsignedAMinusB
, addUnsignedBothNonzero
Expand Down
8 changes: 4 additions & 4 deletions tutorial/Float/compare.dhall
Original file line number Diff line number Diff line change
Expand Up @@ -216,13 +216,13 @@ let zeroTorsor = { x = 0, y = 0 }

let computeTorsor
: Integer TorsorType
= {-
=
stop.reduce_growth
Integer
stop.predicate_Integer
TorsorType
zeroTorsor
-}

( λ(i : Integer)
if Integer/positive i
then { x = Integer/clamp i, y = 0 }
Expand All @@ -233,13 +233,13 @@ let computeTorsorForBothNonzero
-- We define "torsor(a, b)" as any pair of `Natural` numbers (x, y) such that floor(log_10(a)) - floor(log_10(b)) = x - y.
: Pair Float Float TorsorType
=
{-

stop.reduce_growth
(Pair Float Float)
(λ(pair : Pair Float Float) stop.predicate_Natural pair._1.mantissa)
TorsorType
zeroTorsor
-}

( λ(pair : Pair Float Float)
let a = pair._1

Expand Down

0 comments on commit 22baef5

Please sign in to comment.