+ 27

[ASSIGNMENT] Triangles Forming a Square

Form a square by spliting it diagonally an into 4 triangles (top, left, bottom, & right) and filling each in with numbers. The triangles should be filled out in the order listed above. Numbers on the diagonals belong to the first triangle to be filled in. Within a triangle, start at the top leftmost point, go as far right on the row as needed, before starting the next row as far to the left as possible. Column spacing must be maintained for the entire square. You must handle 3x3 to 9x9 squares

21st Feb 2018, 1:40 PM
John Wells
John Wells - avatar
12 Answers
+ 16
tricky
16th Feb 2018, 10:21 PM
jay
jay - avatar
17th Feb 2018, 10:20 PM
Oma Falk
Oma Falk - avatar
+ 6
@john fixed/unfixed (-;
17th Feb 2018, 11:17 PM
Oma Falk
Oma Falk - avatar
+ 5
@Oma, nice. However, your fixed size doesn't follow my request to support 3 to 9 based on user input or random number.
17th Feb 2018, 10:34 PM
John Wells
John Wells - avatar
+ 5
As I didn't know Python completely ,my code will not have such a great function or....... So I code this challenge with the best of my coding... Run this!!!?!! https://code.sololearn.com/cY13XC3qsGUQ/?ref=app
23rd Feb 2018, 3:52 PM
Shivadharshini Nagaraju
Shivadharshini Nagaraju - avatar
+ 4
Now my code should work correctly for all sides: https://code.sololearn.com/cyQRu2uBeqmH/?ref=app
25th Feb 2018, 3:58 PM
Paul
Paul - avatar
+ 4
My latest lesson has been submitted. This code has the rules and solves it. https://code.sololearn.com/c0g34cgteZjA
18th May 2018, 2:32 AM
John Wells
John Wells - avatar
+ 3
My latest assignment lesson code. https://code.sololearn.com/cZV21DN7y959
22nd May 2018, 9:26 AM
John Wells
John Wells - avatar
+ 3
For a up to date list of all my assignments/challenges see: https://code.sololearn.com/WwCPr427zPjD
20th Jul 2019, 6:49 PM
John Wells
John Wells - avatar
23rd Feb 2018, 6:59 PM
John Wells
John Wells - avatar
+ 2
Since they don't want me posting challenges and who knows if lessons will ever get approved, I'm posting my other submitted lessons here. Please comment on my program for any you choose to try. https://code.sololearn.com/cajCn2Rz8cRa https://code.sololearn.com/chTd069rcE9H https://code.sololearn.com/cOUl0TPezP8M https://code.sololearn.com/cTno1cs3lzAA
28th Mar 2018, 5:20 PM
John Wells
John Wells - avatar