# SMS

**Discrete Mathematics**Level 3

A **semimagic square** is an arrangement of integers in a square grid, where the numbers in each row or column adds up to the same number, which is called the **magic sum**.

Consider the \( 2 \times 2 \) square grid below.

\[ \begin{array} { | c | c | } \hline a & b \\ \hline c & d \\ \hline \end{array} \]

How many ways are there to fill each square with an integer from 1 to 10, such that the sum of each row and column is the same?

**Details and assumptions**

The integers may be used multiple times. For example, the square grid with all 1's satisfies the conditions.