DURHAM, N.H. — Crowds refused to let a thunderstorm keep them from seeing President Obama in New Hampshire on Monday.

Many got soaked as they waited outside Oyster River High School. Once they got inside, they packed the school gym and shouted “O-BAM-A” and “Four more years!” from the bleachers.

Kimberleigh Peet of Newmarket said her two sons, ages 7 and 11, persuaded her to bring them to the event. The stay-at-home mom voted for Obama in 2008 but is undecided so far. She says she’s concerned about the level of unemployment.

Peet is just the type of voter Obama and Republican Mitt Romney are hoping to sway in New Hampshire, considered one of a handful of swing states. After spending the afternoon in Durham, Obama planned to head to Massachusetts for several fundraisers.

Skipping a suit jacket, Obama took to the podium in rolled-up sleeves as about 1,100 people packed a school gym that was sweltering without air conditioning. The president spoke for about 30 minutes, his talk centered on ways to improve the economy and help the middle class.

Obama talked about the importance of helping students afford college, boosting small businesses, and creating domestic jobs. He said Romney’s old company had outsourced jobs abroad, and that Romney’s campaign tried to say there was a difference between “outsourcing” and “offshoring” jobs.

“You need someone who’s going to wake up every single day and fight for American jobs,” Obama said.

The president got a standing ovation for that, as he did when he said he was running for office again to do “some nation building here at home” after “a decade of war.”

He told the audience the election would be a close one, and the opposition’s ads would blame him for economic problems.

“That’s what the scary voices in the ads will tell you over and over and over again,” he said.

Oyster River principal Todd Allen said afterward that the president’s message about higher education resonated with him, and his talk inspired students who got to see him.

“It’s a historic opportunity to see the president in your own school,” the principal said.

About 20 protesters also came out to picket the event, some crowding under a tent.