Shoelace formula for polygonal area: Difference between revisions

Removed useless "import math". Removed useless "$" in "echo $shoelace(points)".
(Added 11l)
(Removed useless "import math". Removed useless "$" in "echo $shoelace(points)".)
Line 1,143:
 
=={{header|Nim}}==
<lang nim>import mathtype
 
type
Point = tuple
x: float
Line 1,160 ⟶ 1,158:
var points = [(3.0, 4.0), (5.0, 11.0), (12.0, 8.0), (9.0, 5.0), (5.0, 6.0)]
 
echo $shoelace(points)</lang>
 
{{out}}
 
<pre>30.0</pre>
30.0
</pre>
 
=={{header|Perl}}==
Anonymous user