Skip to content

Instantly share code, notes, and snippets.

function getJSONOuter(cityName) {
/*
if (!cityName) {
// no need to put a var in front of cityName since cityName already exists as an input parameter
var cityName = "Calgary";
}
// line 3-6 ensures that cityName can't be null so no need to check against null on line 8.
// triple equals (===) is almost always preferred to double equals (==). try to find out what the difference is.