When many people think of New Haven, they focus on Yale University or its noted theater community. But Mayor John DeStefano Jr. thinks of pastries.

DeStefano gave a lecture titled “Building Competitive Cities” at the Yale Law School Tuesday afternoon. The lecture, which was attended by about 60 people, focused on the current state of affairs in New Haven. After a late start, DeStefano — who was recently elected president of the National League of Cities, a national lobby group for roughly 18,000 cities and towns across the country — gave evidence of the improvements that New Haven has seen in the last few years but also explained why progress is hard to achieve.

And he consistently compared the Elm City to the hole in the middle of a doughnut.

He used the analogy to refer to the small size of the city in comparison to others in the country, which he characterized as full doughnuts. But DeStefano only used the doughnut hole insofar as it is a small object — not to compare cities on New Haven’s periphery to the rest of the tempting treat.

But aside from desserts, DeStefano focused much of his lecture on the progress New Haven has made in recent years. DeStefano quickly outlined six “recipes for success” for the city, including “Schools and Children,” and “Civility and Personability.”

He also cited New Haven’s ability to distinguish itself as a positive quality of the city.

“Many places are losing their sense of identity,” he said. “They have to ask themselves ‘What are they good at?’ That’s something many cities struggle with.”

He said New Haven’s arts community is a key to branding the city in a positive light but referred to recent cuts in state funding as a factor that inhibits further improvements.

“We had no money 10 years ago; now we have some money, and now the state’s trying to take it away,” DeStefano said.

One of the main problems that DeStefano talked about is the condition of the school system. Despite recent changes, including a return to a system where children attend the same school from kindergarten to eighth grade, the school system is still the second-lowest performer in Connecticut.

“Our teachers are working very hard,” said Ward 24 Alderwoman Elizabeth McCormack. “Our kids today face a lot of problems.”

But Ward 26 Alderwoman Lindy Gold said New Haven provides “unparalleled” opportunities to those students who are motivated enough to utilize them.

“I have plenty of friends from the suburbs that choose to send their children to New Haven Public Schools because of the opportunities there,” she said. “It’s the children who are less motivated or who need more remedial attention who need more focus and more work.”

DeStefano said New Haven’s public schools bring in more suburban children than any other place in the state.

At the end of the lecture, DeStefano opened up the floor to a question-and-answer period. But he did not reply warmly to some of the queries.

When asked about town-gown relations, he said, “This isn’t about Yale.”

But he mentioned his apprehension about current relations between Yale management and employees, saying he “feels like a kid in a divorcing family” and that the two groups “need a good marriage counselor.”

Another audience member said he was concerned about the new location of the Gateway Community College. The man said the college would not benefit the city because its students may not have a large amount of disposable income. The mayor said the man’s statistics were wrong and that the simple volume of people that will be brought into the city would be a clear benefit.