![]() |
How do you write the Magic Square program using c? |
[Edit] |
[Edit]
Answer
You have to create 9 empty labels on the gui, then randomize 9#'s. assign each random number to the labels in the 3x3 square. ( you have to keep in your head where each random number will be). Then create a loop that does not end until each row, (labels 1-3), each column (labels 1,4,7), and diagnal ( 1,5,9) are different unique numbers and they add to 15(or the magic number).
First answer by ID1173573936. Last edit by ID1173573936. Question popularity: 26 [recommend question]




