Skip to content

Commit 83df2fc

Browse files
authored
fixes #880 (#1037)
1 parent 6f7425c commit 83df2fc

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

xml/chapter4/section3/subsection1.xml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -648,6 +648,18 @@ function a_pythogorean_triple_between(low, high) {
648648
}
649649
</JAVASCRIPT>
650650
</SNIPPET>
651+
<SOLUTION>
652+
<SNIPPET>
653+
<JAVASCRIPT>
654+
// solution by GitHub user jonathantorres
655+
656+
function an_integer_between(low, high) {
657+
require(low &lt;= high);
658+
return amb(low, an_integer_between(low+1, high));
659+
}
660+
</JAVASCRIPT>
661+
</SNIPPET>
662+
</SOLUTION>
651663
</EXERCISE>
652664

653665
<EXERCISE>

0 commit comments

Comments
 (0)