It was not just nuns, nor just Catholics. Corporal punishment was common in most places in the western world. I know of schools in Texas and California where kids where still pattled into the mid 1960s. It is still common in the Middle East. Over time, we have all learned better ways of educating kids.
Another example is the Salem Witch Trials, if a woman was thrown into the water and drown, the judge would acquit her, if she floated she was a witch, and was burned at the stake. Now these where Puritan Protestants, very anti-Catholic. In England the Star Chamber held secret trials, gave the accused no recourse to witnesses, and used torture to obtain the “truth” which was really just what the court wanted to hear. Also a Protestant court, which condemned many Catholic priests to death for not converting to Protestantism. So the Inquisition in Spain was not really something unusual for the time. It followed the belief of the people at the time that nobody would give an honest answer unless they where tortured into telling the truth. There are those who report that the same thing goes on today, (Water-boarding etc).