The answer is yes, Animate object would work on a corpse. The exact effect would depend on the size of the corpse.
While there are specific defined terms in D&D 5e there are also a equal number of that rely on what the word means in English.
Object - a material thing that can be seen and touched.
Creature - an animal or person.
However there is a caveat. In various effects, powers, and abilities. The D&D 5e rules are consistent in referring to creatures as things that are living or animate. Objects as inanimate things like tables, chairs, rocks, books, feathers, etc. It not spelled out but it is consistent.
The things to remember is that D&D 5e rules are not to function as a wargame. They do not define the boundaries of what is possible during a campaign. The setting is what defines that. Instead they are a tool to aid the referee in adjudicating the action. For example the description of humans don't spell out every detail that could come up. The mechanics about humans are those that the authors feel that are useful or come up often. The important of which is the effect being human on character creation. The author expect referee to use what they know about humans to adjudicate anything that the rules don't cover because it is implied that humans in a D&D setting are just like people in real life only living in that world.
One implication of this is that animate objects doesn't change any other physical property of the object other than to animate with the stats provided. If you were to say animate a block of salt, possible considering what salt miners carved out of their mines, and it was to walk into water, then it is reasonable to rule that it would be affected adversely as salt dissolves in water. Perhaps by treating water as a acid attack on the animated object.
So a corpse animated as a object would still be a corpse and subject to decay, smelling bad, etc. It would not gain the benefits of being undead although at first glance it would be hard pressed for a character to tell the difference. One area where I can see the difference being important is trying to animate a skeleton. It is reasonable to assume that the various create undead spells joins the bones together to form a complete animated skeleton. While a long dead skeleton is merely a pile of separate objects of bone.
For stuff that has no real world analogue, elves, magic, etc. The authors expect the referee to fall back on their knowledge of the fantasy genre. Because the implied assumption that D&D is being used to depict a fantasy setting. Which is why they included a list of inspirational works in Appendix E on page 312.
In fantasy it is tradition for some spells to work on anything, a lightning bolt doesn't care if its target is a person, animal, or a piece of furniture. Some spells to only work on people, for example charming or enchanting a princess. And other spells to work only on objects, like the animated furniture from Fantasia.
From the "Combining Magical Effects" section of the Player's Handbook (p. 205) and the Basic Rules (p. 85):
The effects of different spells add together while the durations of those spells overlap. The effects of the same spell cast multiple times don't combine, however. Instead, the most potent effect — such as the highest bonus — from those castings applies while their durations overlap, or the most recent effect applies if the castings are equally potent and their durations overlap.
This rule can lead to one of two different rulings:
- The DM could rule that, since Enlarge/Reduce is a single spell, the more recent casting of it (Reducto's) would take precedence, and Inflatoman would not only return to normal size but actually become Small.
- The DM could rule that Enlarge and Reduce — while the same spell — are considered separate for the purpose of combining effects, and rule that the two effects cancel out, resulting in a Medium-sized Reducto.
If Engorgo were to stop concentrating, then Inflatoman would either remain Small (option 1) or become Small (option 2). If Reducto were to stop concentrating, then Inflatoman would become Large in either case.
Thank you to @V2Blast for notifying me of the 2018 PHB errata on this!
Best Answer
Alive or dead, it stays enlarged for the duration of the spell.
Unless otherwise stated, a spell lasts for its duration.
The only rule that covers general spell duration is a small section on page 203 of the PHB:
And the rules that cover monster death aren't very extensive either. Page 7 of the Monster Manual says, under "Hit Points":
And PHB page 198 says, under "Monsters and Death":
Other than that, there's no specific rule that says spell effects end on a creature when it dies, unless the creature is the one casting and the spell requires concentration (PHB, p. 203), so they should carry on (exceptions might be made at the DM's discretion).
Thus, the creature would stay enlarged for the full 1-minute duration of the spell, whether dead or alive, unless your concentration is broken.