CompareNat.out 1.3 KB

123456789101112131415161718192021222324252627282930313233343536
  1. EXECUTED_PROGRAM
  2. ret > ExitSuccess
  3. out > CompareNat.compare =
  4. out > λ a b →
  5. out > let c = a < b in
  6. out > case c of
  7. out > Agda.Builtin.Bool.Bool.false →
  8. out > let d = b < a in
  9. out > case d of
  10. out > Agda.Builtin.Bool.Bool.false → CompareNat.Comparison.equal _
  11. out > Agda.Builtin.Bool.Bool.true →
  12. out > CompareNat.Comparison.greater (CompareNat._<_.diff (a - b - 1) _)
  13. out > Agda.Builtin.Bool.Bool.true →
  14. out > CompareNat.Comparison.less (CompareNat._<_.diff (b - a - 1) _)
  15. out > CompareNat.compare-lots =
  16. out > λ a b →
  17. out > let c = a < b in
  18. out > case c of
  19. out > Agda.Builtin.Bool.Bool.false →
  20. out > let d = b < a in
  21. out > case d of
  22. out > Agda.Builtin.Bool.Bool.false → "equal-equal"
  23. out > Agda.Builtin.Bool.Bool.true → "greater-greater"
  24. out > Agda.Builtin.Bool.Bool.true → "less-less"
  25. out > CompareNat.main =
  26. out > Common.IO.then
  27. out > () () _ _ (Common.IO.putStrLn (CompareNat.compare-lots 1500 2000))
  28. out > (Common.IO.then
  29. out > () () _ _ (Common.IO.putStrLn (CompareNat.compare-lots 2000 1500))
  30. out > (Common.IO.putStrLn (CompareNat.compare-lots 2000 2000)))
  31. out > less-less
  32. out > greater-greater
  33. out > equal-equal
  34. out >