[ad_1]
Try changing console.log(country) to console.log(people.country);.
country isn’t defined where you call console.log. country is only defined within the people object.
1
[ad_2]
solved Uncaught syntax error unexpected identifier JavaScript objects [closed]