Miles-long traffic jams, gasoline shortages and blackouts that may last for weeks defined the challenges facing New York City and New Jersey as the region struggles back to its feet after the chaos triggered by superstorm Sandy. The Pentagon is flying 17 planes carrying more than 600 tons of power-restoration equipment, vehicles and workers from Southern California to help New Jersey and neighboring states with recovery efforts. National Guardsmen doled out food and water from distribution centers, and the utility Consolidated Edison Inc. gave dry ice to people with powerless refrigerators.