A Baldwin student posted a public Snapchat video showing three guns — he said he’d take one to school — and ran from officers who came to arrest him Thursday, Nassau police said.

Shamari Gerrow, 20, sprinted from Baldwin High School and ran past a shopping center, where he tossed what appeared to be a black handgun into a trash bin, before he was caught on nearby Emerson Avenue about 10:35 a.m., police said.

Gerrow, of Carleton Place, was arraigned Friday on charges of unlawful possession of a weapon upon school grounds and making a terroristic threat. He was ordered held on $100,000 bond, $50,000 cash bail.

Police said Baldwin High School officials found out he had posted a Snapchat video with a message saying he was mulling over which one to take to school.

School officials called 911, and Gerrow ran as soon as he saw the officers, police said.

The weapon retrieved from the trash turned out to be a black, air-powered pistol, police said.

advertisement | advertise on newsday

The school district released the following statement on its website: “You may have heard about an incident which occurred off school grounds yesterday. School District staff became aware of a situation that required the attention of law enforcement and notified the police. The police were able to address this off campus situation immediately. Our school day was not interrupted.

“When any information arises that causes concern, it is addressed immediately. We insist on an environment that ensures the safety of staff and students at all times and as a result, we act accordingly.”