The youthful man with a blue ballpoint pen behind his right ear and walkie-talkie on his belt stood sentinel one morning last week outdoors. Teenagers flowed past: a girl with her nose in a paperback, a boy with a do-rag, a girl with hot-pink beads in her cornrows, a boy with a smirk.

"Why are you smiling?" Thomas Anderson asked.

"Why are you smiling?" the boy shot back, without breaking stride.

" 'Cause I see you," Anderson said, swiveling to keep his eyes on the boy. "You know where all your rooms are?"

The boy slipped inside. No reply. The DuVal High School principal sighed.

"He'll go in this door and go out the back door," Anderson predicted. "He'll end up being marked absent."

It was just before 8:30 a.m., with classes about to start. Soon Anderson would be proved correct, and the habitual truant -- last seen darting around a hallway corner in a futile attempt to escape notice -- would be booted out of school, perhaps for good.

Of many challenges in a low-achieving school, sometimes getting students to class is the hardest. Anderson learned that again this month, when six students were arrested after a school bus fight morphed into a melee. Police used pepper spray and a stun gun in an incident that spun strangely out of control.

Anderson has one of the toughest jobs in education: leader of an urban public high school with nowhere to go but up. High teacher turnover, low test scores, transient students, a reputation -- perhaps overblown -- as a "tough" school, racial achievement gaps, a working-class parent population that can be hard to reach. It's a litany familiar to many principals across the country.

Anderson's vision is nothing flashy: to lift DuVal, student by student, teacher by teacher.

Last year, Anderson left an assistant principal's post at Watkins Mill High School in Gaithersburg to come to Lanham for his first principal's job. Moving from Montgomery County to Prince George's County set him apart. More often, up-and-comers move in the other direction, to the higher-performing and more affluent system. Anderson saw opportunity in this school on Good Luck Road.

He was 33 when he arrived, unusually young for a demanding job that pays a bit more than $100,000 a year. Now just shy of 35, Anderson is settling in as the leader of 135 teachers and staff members and 1,607 students. "But I don't know how really settled you ever feel," he said. "There's always something."

As he began his daily rounds last week, Anderson said student attendance is about 90 percent, up four points this year. Still, it's a constant chore to get students to class on time. Dozens arrived this morning on late buses.

Starting the day minus three assistant principals who are usually on hand, Anderson reached a fourth by walkie-talkie.

"Mr. Jackson, what's your location?" he asked. "Right now, it's me and you. Be aggressive. Get them out of the halls."

Anderson reminded passing students of the hour and the rules: nothing worn on their heads inside (with exceptions for religious reasons), no cell phones on, no wearing ear buds or headphones. "Hey, are you new?" he asked one.

"I can't wear my headband?" the boy asked, peeling it off reluctantly.

Another boy was wearing a black T-shirt with the message "Ramone -- I miss you." Student Ramone Paige-Weaver was shot to death a year ago in a car after school. Two other students died during that school year in car crashes. There have been no fatalities this year.

Anderson walked past a poster that declared "Anything is Possible," a bulletin board with pictures of notable alumni -- including Rep. Albert R. Wynn (D-Md.) -- and a plaque noting that the school was named for a 19th-century Supreme Court justice.

He entered a 10th-grade government class, where teacher Franco Crispi was quizzing students about a political cartoon that depicted Hurricane Katrina and President Bush.

"One thing I look for," Anderson whispered, "when students come into a room, are they engaged somehow? Are they getting warmed up?"

Next door, Anderson peeked into an Italian class with seven students. Francesca Randazzo, new to the school, teaches beginning Italian and beginning Latin, expanding DuVal's foreign language offerings. "So far, so good," Anderson said. "The classes are not large, because you have to grow them."

A nearby science class showed the school's new English for Speakers of Other Languages program. Students worked in small groups according to their native tongue: French over here, Spanish over there.

Anderson said he speaks bits of Spanish with some of his students. "If they can see you as a person, for a split second, then you have them," he said. "You use whatever you can to get to them."

Anderson attended public high school in East Hartford, Conn., and graduated from Phillips Academy in Andover, Mass. In college, he ran 400 meters competitively, with and without hurdles. Nowadays, the 5-foot-7 principal faces taller hurdles.

"Quite often, we end up hearing negative things about this building from people who never set foot in it," Anderson said. "We don't get the benefit of the doubt."

Anderson is starting with basics, logistically and academically. He moved ninth-graders into a separate wing and isolated them with 10th-graders at lunch to help nurture the younger students. He ordered up a booklet of course offerings. The school has six Advanced Placement classes but ranks last in the metropolitan area in the percentage of students who take AP exams. Anderson said he's more concerned about getting students ready for those exams than pumping up the numbers. But he pointed out that the school's combined SAT scores rose 45 points in the last school year, to 846 on the old 1600-point scale, the county's largest gain.

The staff buttonholed him throughout the day. A campus expansion project has fenced off a lot -- where should people park? No easy answers. E-mail went down -- was it a power surge? Again, no answers. He frequently fished a BlackBerry from his pocket and checked his schedule on a belt-clipped Treo.

In another room, a guard and a campus police officer watched footage from 18 security cameras. All quiet. As he moved through the building, Anderson checked the perimeter to ensure that doors were locked.

Later, he met with a woman from the county school system who urged him to seek a federal grant -- $70,000 over three years -- to help the school start an introductory aerospace engineering program. Anderson said he was game.

He lamented that DuVal tends to lose students to science and technology programs at nearby Eleanor Roosevelt High School in Greenbelt -- the county's most prestigious public school -- and Charles H. Flowers High School in Springdale. Anderson said he also wants to tap educational opportunities at nearby Goddard Space Flight Center. "No other school in the county can say they're across the street from NASA," he said.

Anderson's wife works in public affairs for the space agency. In his office are photos of their 4-year-old sons and a daughter born in September. The family lives in Silver Spring.

Posters of Booker T. Washington and Albert Einstein hang on the walls along with Anderson's bachelor's degree from the University of Rhode Island (1993) and master's degree from Howard University (1996). On the floor, institutional orange carpet. On the bookshelves, dry education reports in three-ring binders and the book "Race" by Studs Terkel. (Most of his students are black.) On his desk, a pizza takeout receipt and a near-empty bottle of Snapple lemon iced tea. And on the radio, low-volume urban music on 95.5 FM.

At a Junior ROTC class, cadets were being fitted for overcoats. Retired Air Force Col. Harold Ray, 58, in his first year as program leader, said Anderson drew him to DuVal. "Here's a man that could have gone anywhere and done well," Ray said.

After lunch, a crowd suddenly swelled at a distant hallway intersection. "Hold on," Anderson said, calling security and bolting to the scene. The disturbance, just heated words between girls, ebbed. "Ladies and gentlemen, let's go," Anderson said, shooing bystanders.

About that melee early this month: A boy and a girl who were fighting on the bus were suspended for 10 days. Anderson disciplined no one else. But he got an earful from students and parents. Some kids said the police overreacted; some parents said the school had to exert some control over unruly bus passengers. The principal sought to defuse the situation. He appealed for help from home but said he would do his part to set the tone.

"Most of the kids respect him," said Crispi, a teacher so dedicated to the school that he has its mascot, a tiger, tattooed on both forearms. "A few of the kids fear him, for good reason. They know he will follow up with what he says."

The next day, Anderson surprised his students with a motivational assembly featuring hip-hop and go-go music. The performers aimed to get students thinking about how to get ahead academically and stay out of trouble with the law.

Anderson introduced the group and then ducked out while his 11th- and 12th-graders partied in the gym amid pounding decibels. He left campus for a student expulsion hearing.

Thomas Anderson, principal of DuVal High School in Lanham, signs a permission slip for a student to wear a head scarf for religious reasons.Principal Thomas Anderson, left, and the Rev. C.J. Blair, who came to the school with other religious leaders and musicians for a motivational event.