Menelaus's theorem

From JSXGraph Wiki

a
b
c

The underlying JavaScript code