GORHAM — Matthew Alvarez needed just 41 seconds to score Tuesday night.

It was enough to help Deering remain undefeated with a 1-0 victory against Gorham in an SMAA schoolboy soccer game.

Alvarez’s shot ricocheted off a defender’s ankle and into the net.

“The ball just came right in front of me and I had a chance to shoot it,” Alvarez said. “I shot it, it deflected off somebody and went over the keeper. It wasn’t a pretty shot.”

Didn’t have to be.

Gorham (3-1) controlled the second half but wasn’t able to tie it.

Deering dictated play early. In the 25th minute, Ben Peterson headed a throw-in from Stephen Ochan straight toward the goal but keeper Matt Bennett (five saves) was in position for the stop.

Gorham settled in late in the half and created several quality chances.

Corey Nadeau took two one-time shots from in front in the final five minutes of the half, but one went right and the other clanged off the crossbar.

Gorham continued to dominate in the second half. It took a perfect game from goalie Anthony Russo (five saves) and a couple of lucky bounces to preserve the Deering win.

“That wasn’t the game plan,” Deering Coach Joel Costigan said. “I think our communication lacked in the second half and Gorham was able to take advantage of it, put a lot of pressure on us. That game couldn’t have ended sooner.”

Gorham had a chance to tie in the 54th minute when Cody Elliott came down the right side with one man to beat. His shot went past Russo and defender Ahmed Adnan but missed the net on the near side.

Two minutes later, Morgan Hager-Perry of Gorham tested Russo with a blast from outside the box, but Russo calmly caught the ball.

“Anthony’s an excellent goalkeeper, one of the best in the league,” Costigan said. “Definitely, definitely, the saves he made were very big and kept us in the game. I don’t think we could have won without him.”

Gorham thought it had tied the game in the 62nd minute on a shot that appeared to float down and under the crossbar, but Russo stopped it just shy of the goal line.

“They’ve got a good keeper,” Gorham Coach Tim King said. “He’s very aggressive and sure-handed, and he doesn’t give rebounds. You’ve got to have a good shot to beat him.

“Obviously you’re really disappointed when you don’t come out ready to play and you give up a goal in the first minute. That’s just a lack of preparation. But we had some good chances after that, and I thought from 20 minutes left in the first half and most of the second half we carried the play and we were scrappy. We’re a young team and we’ve got a lot to learn but we’re making progress.”