There were a few stories; one of them was about a society that didn't age but their brains did and they had to put their memories on tapes to preserve them. Also no new people could be born.
The main character comes across a boy whose pet dog had died, so he creates a machine so he can get this boy a puppy. He realizes he's the one who created the anti aging machine and wants to turn it off.
Another one was about a judge who lives in a society where the way their court system works is that they shoot at the accused, if they're not guilty a God of some kind will intervene and prevent it. One judge realizes how broken the system is when a lower class girl is put on trial for having sex or something with an upper class boy but the boy isn't facing justice.
Please help, even a name of an author whose work sounds similar. I have been searching for years one of my favorite short story collection when I was a teenager, but now I can't even remember a title!