At My Fingertips

Triangles

Description

Implement the equilateral_triangle function, the isosceles_triangle function and the right_triangle function to recreate the following graphics. Your implementations should use PyTamaro's more general triangle function.

triangles

The Equilateral Triangle

An equilateral triangle has all sides of the same length and all angles of 60°.

Loading...

The Isosceles Triangle

An isosceles triangle has two sides with the same length.

Loading...

The Right Triangle

A right triangle has an angle of 90°.

Loading...

Now let's check your result! Using #, comment and uncomment the show_graphic statements one at a time to check your results one by one.

Loading...

This activity has been created by LuCE Research Lab and is licensed under CC BY-SA 4.0.

Triangles

Logo of PyTamaro

PyTamaro is a project created by the Lugano Computing Education Research Lab at the Software Institute of USI

Privacy PolicyPlatform Version c3a8286 (Mon, 14 Oct 2024 13:30:28 GMT)