It is always clear, in the book, that the entire intention of the Scholomance is to make the school as safe as possible - the builders were, after all, planning on sending their own children, grandchildren, etc. All of the dangers, then, are entirely the result of the limitations and failures in the school's design and construction.
Near the beginning of the book, El is grousing about being saved by Orion and narrates:
We’re not meant to all survive, anyway. The school has to be fed somehow.
This is discussed later in the book when another character talks about how many people Orion has saved (approximately 600) and the fact that the amount of food available in the cafeteria is not enough for everyone.
And then at the beginning of chapter thirteen:
We’d made it to our senior year, the one in two odds we’d beaten so far.
Also, from half-way through chapter one, talking about graduation:
About half the senior class—that is, half of the ones who’ve managed to survive that long—makes it.
There are three main features of the school designed to protect the students. The first is the fact that only the Graduation Hall is connected to the outside world, the rest is surrounded by the void. The second is that there is very little direct connection between the Graduation Hall and the rest of the school. Third is the cleaning cycles.
There are at least three Mortal Flame cleaning cycles specifically mentioned in the book:
- Graduation Hall just before graduation
- The main halls and stairwells of the school twice a year
- Kitchen after each meal is served (though it wasn't clear exactly how that worked)
Near the end of chapter three, the protagonist tells us:
It’s one of the few situations in which a wall of mortal flame might actually be called for: in fact that’s how the school cleans out the cafeteria and does the twice-yearly scouring of the halls.
And half-way through chapter six:
The builders knew that some mals would wriggle their way up to us, so twice a year the halls get a good scouring. A very loud warning bell goes, we all run for our dormitory cells, shut ourselves in, and barricade our doors as thoroughly as we can. Then massive cleansing walls of mortal flame get conjured up and sent running on their merry way throughout the whole building, from top to bottom, incinerating hordes of desperate fleeing mals.
And shortly after that:
If you’re wondering why they don’t also run this excellent system down in the graduation hall to clear out the mals before dumping in the seniors, the answer is they meant to, but the machinery down there has been broken since about five minutes after the school opened. No one’s going down to the graduation hall to do maintenance.
Since the system in the Graduation Hall is the only one that failed, only the survival rate of students who actually reach graduation is affected.
Near the end of chapter one, El says:
Even enclave kids were getting eaten more often than not before the school was built, and if you’re an indie kid who doesn’t get into the Scholomance, these days your odds of making it to the far side of puberty are one in twenty. One in four is plenty decent odds compared to that.
And also:
For all that I want to go home every minute of every day in here, I know perfectly well it’s actually unbelievably good luck to be here.
Half-way through chapter three:
The place is filled to capacity with kids; there are two applicants for every spot as it is
About a quarter of the way through chapter twelve:
The enclaver kids do make it out alive almost all of the time—their survival rate usually hovers around eighty percent, a substantial improvement over the forty percent chance they’ve got if they stay home.
And that's even without the end-of-year cleanup of the graduation hall.
So, while it is clear that the Scholomance is an imperfect solution to an impossible problem, it is also the best available chance of surviving to adulthood for anyone fortunate enough to get in.
Going back over this after reading The Last Graduate.
Jontia's comment is spot on - the intention was always to have a 0% fatality rate. In fact, the motto of the school is even built into it:
the silver letters inlaid into the old scarred wood: TO OFFER SANCTUARY AND PROTECTION TO ALL THE WISE-GIFTED CHILDREN OF THE WORLD
So what went wrong?
It turns out that, unbeknownst to El, the problem has been endlessly studied by the best people in various major enclaves and there is not, actually a solution.
The problem starts with this:
"Okay, so -" Aadhya said after a moment. "This is all because the cleansing machinery worked. So we just need to find a way to keep it working, for good."
That did sound promising, but Alfie said, "Oh, bugger," half under his breath, and then said, "You can't. The cleansing machinery can't be preserved. You can fix it, but you can't keep it working. Four years is the absolute most you can get. The agglos will do for it by then."
A couple of paragraphs later, he explains the problem with agglos:
"That's why you can't ward them out," Alfie said. "Mortal flame is - well, it's arguably an entity, and one that consumes mana that it doesn't make itself. If you want to conjure a mortal flame and send it out, you can't ward the artifice you're doing it with against mana-consuming creatures. You have to ward it against malice. But the agglos aren't malicious. They never take mana against resistance. They just nibble on this thing we've left sitting out near them, and sooner or later they make a hole in it, and then they squirm inside and take bits of it until the whole thing comes apart. London enclaves got a laboratory with an Anglo farm that's been lookin for ways to keep them out for the last century. If we could, it would be worth doing anything, spending any amount of mana, to get another team in to do a real repair. But we can't find anything that works for longer than bloody wrapping the thing in tinfoil - the agglos like that stuff so much they'll eat all of it before they bother going into the artifice. And that would get you four years."
Then somebody brings up the question of repairing the machinery regularly, and he continues:
"They've thought of that. Posting guards, sending in maintenance crews every month, all of it. And that would handle the agglos. But you can't pay anyone enough to do it, because a new maw-mouth will come into the school, very soon. There's a trace on the doors. Usually one or two manage it every year - they're oozes, those are always the hardest to keep out of anywhere."
And we know, at this point, that only two people in the entire world have faced down and defeated a maw-mouth so they are left with a seemingly insoluble problem - which clears the stage for what they actually do in The Last Graduate.