lukew3 / mathgenerator

A math problem generator, created for the purpose of giving self-studying students and teaching organizations the means to easily get access to high-quality, generated math problems to suit their needs.
https://lukew3.github.io/mathgenerator
MIT License
680 stars 175 forks source link

Broken Area of Triangle #359

Closed jsun1590 closed 2 years ago

jsun1590 commented 2 years ago

Hi, the area of triangle function is broken. Answers are not rounded and some answers are broken.

Example

Input a = 15 b = 1 c = 20

Output (2.623718239906474e-15+42.8485705712571j)

I would like to be assigned if possible.

Thanks.

EDIT: Upon further inspection, the issue arose because the generated sides cannot actually make a valid triangle, such that every side has to be smaller than the sum of the other 2 sides.

lukew3 commented 2 years ago

Good catch! I've assigned the issue to you.