A woman injured a boy with a knife in a parking lot in the city of Ube, Yamaguchi Prefecture, on Wednesday before attacking another boy and girl at a supermarket in what appeared to be random attacks, police said.

The children, whose injuries are not considered serious, were nevertheless taken to a hospital.

The police detained the 26-year-old unemployed woman in the nearby city of Onoda, arresting her on suspicion of attempted murder.

The woman, whose identity is being withheld, has admitted the assaults, they said. Police are questioning her in an effort to determine her mental state.

The woman told investigators she attacked the children because she felt irritated.

"I intended to kill the children," police quoted her as saying. "I initially planned to attack elderly people but I changed my mind because children are unable to fight back."

According to the police, the woman assaulted 3-year-old Sho Maeda in the parking lot of a drugstore in a residential area of Ube at around 11:50 a.m. Sho suffered cuts to both arms.

About 20 minutes later, the woman assaulted Satoe Mataga, a 9-year-old girl, and the girl's 7-year-old brother, Mikio, at a supermarket about 1.5 km south of the drugstore, the police said.

They were attacked with what appeared to be a hammer, the police said.

The police later recovered a kitchen knife and a hammer from a car the woman used to try to escape.