This kind of set up is common in quests where you're out to defeat some monsters.
However, if this was how you've set up your own quest, you'll probably notice during testing that the slime count doesn't add up after a battle is over.
In theory, what should be happening here is when both slime are defeated, the two events should run and increase your variable by 1 per slime.
I encourage you to reproduce this set up in your own project to see what happens.
However, what actually happens is when the last slime is defeated, the game goes straight to victory processing and ends up skipping the any troop events that should have ran.
So if you had one slime left, that event won't run upon defeating it. If you used an attack-all skill that decimated both slime in one shot, neither events will run. You will do a lot of hard work with no reward.
Interestingly enough, there isn't really too big of a drawback to simply do a final check of any troop events before you finish the battle.
In RPG Maker VX Ace, I called this the "end phase trigger" which I thought was a cool name but may not be completely accurate. Anyways that will be the name of the MV plugin as well.
Because a final check of any events is performed before the battle end processing, you can actually introduce new mechanics into your battles.
For example, maybe after defeating some foot soldiers, the general appears. This typically isn't possible without some hackish workarounds like setting the soldiers to "immortal" so that the battle doesn't end immediately after all of them have been defeated. And you will likely have other issues to deal with if you had to set multiple soldiers to immortal state.
With one less thing to worry about, this plugin should become an essential part of your eventing toolkit when it's done.