Babies Have Logical Reasoning Before Age One, Study Finds