A square is divided into 9 identical smaller squares. Six identical balls are to be placed in these smaller square such that each of the three rows gets at least one ball (one ball in one square only). In how many different ways can this be done?
(a) 27 (b) 36 (c) 54 (d) 81