In a period (left to right): Nuclear charge increases but electrons are added to the same shell. The increased nuclear pull acts on electrons in the same energy level, pulling them closer. So atomic size decreases across a period.
In a group (top to bottom): Nuclear charge increases, but a new shell is added with each element. The outermost electrons are farther from the nucleus and are also shielded by inner shells. So atomic size increases down a group.
Thus, the opposing effect of addition of new shells in a group overrides the increased nuclear charge, causing different trends in the two cases.
The examiner expects two separate, reasoned explanations — one for period and one for group. The key contrast is: same shell vs. new shell added. Mentioning "shielding effect" for the group trend is a bonus but expected at this level. Do not just state the trend — always link it to the reason (nuclear charge vs. shell addition/shielding).