The Last Question by Isaac Asimov

The Last Question by Isaac Asimov (Science Fiction Quarterly, November 1956)1 is a one of his “Multivac” stories about a giant computer. In this tale, after the computer has been running for several decades, it finally develops a system that provides unlimited solar power for humanity. After this achievement, we then see the Multivac’s two attendants, who are hiding from the publicity in an underground chamber, having a drink and relaxing. Later, an argument develops when one of the two, Adel, contends that that the solar power supply will last forever:

Lupov cocked his head sideways. He had a trick of doing that when he wanted to be contrary, and he wanted to be contrary now, partly because he had had to carry the ice and glassware. “Not forever,” he said.
“Oh, hell, just about forever. Till the sun runs down, Bert.”
“That’s not forever.”
“All right, then. Billions and billions of years. Twenty billion, maybe. Are you satisfied?”
Lupov put his fingers through his thinning hair as though to reassure himself that some was still left and sipped gently at his own drink. “Twenty billion years isn’t forever.”  p. 8

This back and forth continues until Lupov points out that when entropy eventually reaches a maximum (i.e The Heat Death of the Universe, when the temperature everywhere in the Universe is the same), no more free energy will be available. Adell suggests that it may be possible to “build things up again someday”. Lupov disagrees, and so they ask Multivac if it will ever be possible to decrease the amount of entropy in the universe: the computer replies “INSUFFICIENT DATA FOR MEANINGFUL ANSWER”.
The rest of the story telescopes through time until the end of the Universe, with many changes taking place during the various sections: Multivac becomes a much smaller machine, and eventually exists in hyperspace (by this point it is called the “Cosmic AC”); meanwhile, humans become immortal, spread throughout the Galaxy and the Universe, turn into disembodied beings, and later merge into one consciousness. At the end of every section someone asks the same question that Adell and Lupov asked and get the same answer.
Finally, ten trillions years later, just before the last man fuses with AC, the question is asked one last time with the same result. Then, in the timeless interval afterwards (spoiler), AC learns how to reverse the direction of entropy:

But there was now no man to whom AC might give the answer of the last question. No matter. The answer—by demonstration—would take care of that, too.
For another timeless interval, AC thought how best to do this. Carefully, AC organized the program.
The consciousness of AC encompassed all of what had once been a Universe and brooded over what was now Chaos. Step by step, it must be done.
And AC said, “LET THERE BE LIGHT!”
And there was light—  p. 15

The cosmic and temporal sweep of the story is quite well done but the ending is a gimmick better appreciated at age 12. I’d also suggest the story has a religious or mythological ending rather than a proper sense of wonder one.2 Still, not bad I guess.
*** (Good). 4,450 words. Story link.

1. I assumed that this story had bounced from Astounding, Galaxy and F&SF to Science Fiction Quarterly (a much lower-budget publication) but then I found this in Asimov’s autobiography, In Joy Still Felt:

On June 1, 1956, I received a request from Bob Lowndes for another story. I was already thinking about writing another story about Multivac (“Franchise,” which had been the first, had been written as a direct consequence of my introduction to Univac in the 1952 election).
I had worked out ever greater developments of Multivac, and eventually was bound to consider how far I could go; how far the human mind (or, anyway, my human mind) could reach,
So as soon as I got Bob’s letter I sat down to write “The Last Question,” which was only forty-seven hundred words long, but in which I detailed the history of ten trillion years with respect to human beings, computers, and the universe. And, in the end—but no, you’ll have to read the story, if you haven’t already.
I wrote the whole thing in two sittings, without a sentences hesitation. On June 4 I sent it off, and on June 11 I got the check from Lowndes at four cents a word.
I knew at the instant of writing it that I had become involved in something special. When I finished it, I said, in my diary, that it was “the computer story to end all computer stories, of, who knows, the science-fiction story to end all science-fiction stores.” OF course, it may well be that no one else agrees with me, but it was my opinion at the time, and it still is today.  p. 59

2. Tacking on a religious or mythological ending to provide a sense of wonder is not uncommon, e.g. Arthur C. Clarke’s The Nine Billion Names of God.