Skip to content

Commit 0b0f69f

Browse files
author
Shati Patel
committed
QL etudes: Tidy up alternative solns
1 parent 3441696 commit 0b0f69f

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

docs/language/learn-ql/ql-etudes/river-crossing.rst

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -242,8 +242,18 @@ Alternative solutions
242242

243243
Here are some more example QL queries that solve the river crossing puzzle:
244244

245-
- Solutions described in more detail: https://lgtm.com/query/4550752404102766320/
246-
- Solutions displayed in a more visual way: https://lgtm.com/query/5824364611285694673/
245+
#. This query uses a modified ``path`` variable to describe the resulting path in
246+
more detail.
247247

248-
.. TODO: Add more examples + check that the queries are "tidied up" and clear.
248+
➤ `See solution in the query console <https://lgtm.com/query/766398955877740367/>`__
249249

250+
#. This query models the man and the cargo items in a different way, using an
251+
`abstract <https://help.semmle.com/QL/ql-handbook/annotations.html#abstract>`__
252+
class and predicate. It also displays the resulting path in a more visual way.
253+
254+
➤ `See solution in the query console <https://lgtm.com/query/4569245314675800407/>`__
255+
256+
#. This query introduces `algebraic datatypes <https://help.semmle.com/QL/ql-handbook/types.html#algebraic-datatypes>`__
257+
to model the situation, instead of defining everything as a subclass of ``string``.
258+
259+
➤ `See solution in the query console <https://lgtm.com/query/7017582538107942633/>`__

0 commit comments

Comments
 (0)