Charles Moore, 18, of Alexandra Park, was arrested for carrying the sword, which has a 3ft long blade, outside Graham School in Woodlands Ravine on January 22.
Moore, dressed in a black hooded top and wearing sunglasses, appeared before Scarborough Magistrates’ Court on Monday where he pleaded guilty to charge of possession of an offensive weapon in a public place.
Katy Varlow, prosecuting, said: “Just before 3pm Mr Moore left his house with the sword, in a scabbard, hung from his belt. He headed in the direction of Woodlands Ravine where he was spotted by a member of the public.
“The police were called and found Mr Moore sat on a wall eating an sandwich with the sword still on his belt.
“There is no suggestion he took out the sword or brandished it at anyone.”
Defending Moore, Nick Tubbs told the court his client had been diagnosed with autism and also the brain condition encephalitis. He said: “This leads him to become fixated on objects and on this day it was the sword which he wanted to take with him to show a friend. He meant no harm.” The court heard that the sword cost £100 from Ancient Warrior in Foreshore Road. Moore was sentenced to a 12-month community order with 10 days of rehabilitation. He was also fined £20 and ordered to pay a £60 victim surcharge and £85 costs.
The sword will be destroyed.