The president made the comment during a joint news conference with Australian Prime Minister Malcolm Turnbull.
He predicted congressional action will "take place very quickly" on improving the background check system and regulating bump stocks - devices that can be used to effectively turn a legal rifle into a machine gun.
The president continued to say he wants to arm teachers who are trained or have experience with guns and again criticized the school security guard the Broward County Sheriff said failed to enter the school to confront the gunman during last week's shooting in Parkland, Fla. That guard has since resigned.
Trump said that if people think about going into a school to hurt students or teachers, they won't do so if they know people are armed, repeating comments he made in a speech at the Conservative Political Action Conference Friday morning during which he said schools should no longer be "gun free zones."
"We need people that can take care of our children. We're not gonna let this happen again and the way it's not gonna happen again is that they're basically cowards. Innately, they're cowards," Trump said of gunmen who attack schools. "And if they know bad things happen to them once they get into that school by people who love the children, see a security guard doesn't know the children, doesn't love the children. This man standing outside of the school the other day doesn't love the children, probably doesn't know the children. The teachers love their children. They love their pupils. They love their students."
Personnel records show that the deputy who resigned, Scot Peterson, has worked at the school for several years and has been recognized as school resource officer of the year. One evaluation said that Peterson "takes pride in protecting the students, faculty and staff at his school."