Two students with connections to Langley High School died a day apart this week, shocking the Fairfax County school community and sending many of their peers into mourning.

Police released few details about the deaths, on Monday and Tuesday, saying only that both students were 17-year-old males and that one was found in a wooded area of a McLean public park and the other in a home in Great Falls. Police said that they do not suspect foul play and that drugs were not the cause of death in either case.

A county police spokesman, Bud Walker, said investigators “do not believe these cases to be related or connected in anyway.”

County officials familiar with the cases said they believed that the students died as a result of self-inflicted gunshot wounds. But police declined to comment on the causes of death while medical examinations are pending. The Washington Post generally does not identify people who commit suicide.

Many Langley students dressed in black Wednesday and left mementos, flowers and candles at a makeshift memorial in front of the McLean school. Students who gathered there embraced tearfully. The two students who died had been popular athletes at the school.

“Two very tragic incidents struck our school community this week,” Principal Matthew Ragone wrote in a letter to parents Wednesday. “Families are grieving and we as a community grieve with them.”

Reached by phone, the family of one of the students declined to comment; the family of the other did not respond to a request for comment.

Rashad Shakib, 18, a senior at Langley High School who described himself as a friend of both students, said the two deaths have shaken Langley, a school of nearly 2,000 students in an affluent area of the county.

“I will remember his joyous smile and his energy,” Shakib said of one of the students. “He was the greatest guy I ever got to meet. . . . It was so bizarre to lose two amazing kids that excelled in sports and activities . . . in this way.”

Shakib said little school work was getting done as students mourned and wrote notes to the families of the deceased students. Shakib said that the two students knew each other but that he did not know them to be friends outside of school.

“We are a tightknit community,” Shakib said. “It’s a devastating loss.”

County police said the first death was discovered Monday afternoon by officers responding to a report of a body seen in a wooded area of Scott’s Run Nature Preserve. On Tuesday afternoon, officers were called to a home in Great Falls where they found the second teenager’s body.

Students and members of the community wrote about the teens on Twitter, Facebook and other Web sites, but Ragone, the school principal, urged people to refrain from speculating about the deaths.

“Unfortunately, social media is currently littered with untruths,” Ragone wrote. “Please help us and each other by not engaging in these rumors.”

Ragone said grief counselors and members of the school system’s crisis-response team would be available to help students and staff members “cope with their feelings of sadness and grief.”

To students and other members of the Langley community, Ragone said that “it is important that we continue to be there for one another during this difficult time.”