triangles refactored

Thank you Github app
This and it's brother below are _almost_ "too clever". I think it is fine here, but I just want to mention that it is normally not good to be "too clever"