Two dozen city students got a taste of city government Tuesday, carrying on a long-standing local tradition.

Shadowing various department heads and city employees, the high school juniors and seniors participated in Taunton’s annual Good Government Day. “Someday you could be sitting here as city councilors and you could one day go on to become legislators, the mayor or even work in the White House,” Mayor Charles Crowley told the pupils.

He made reference to David Simas, a former city councilor and register of deeds who went on to work on Beacon Hill before landing a job with the Obama administration.

Many of the students said they were interested in one day working in the city government. “I would love to work for the city,” said Meagan Hines, who was learning the ropes in the office of the city tax collector and treasurer.

Office employee Debbie Fasolo spent time showing her the system the city uses to collect tax payments online. “It’s very interesting to see where all the bills go,” she added. “They deal with a lot of paperwork and keep it organized.”

Andrew Cardoza followed Crowley around, getting a taste of daily life in the mayor’s office. “It’s more complicated than I thought,” he said. “I’ve learned a lot.”

T.J. Torres, who also spent time in the mayor’s office, said it was interesting to learn about the work the mayor does on the budget and negotiating contracts with the unions.

Students also sat in on Tuesday night’s City Council meeting and are scheduled to observe the School Committee meeting tonight.

Instead of shadowing a city employee, student Nick Androski experienced life in City Hall as a member of the fourth estate. He shadowed a Taunton Daily Gazette reporter.

“I really want to get experience in journalism and being a reporter,” the high school junior said.

Taunton High social studies teacher Kristen McGonigle, one of the coordinators of Good Government Day, explained that the tradition was started years ago to engage the younger generation in the community and get them interested in local government. A number of past participants have gone on to hold elected offices and city jobs.

“I think it’s a really good experience for them to take part in,” McGonigle said.