Amazon profit more than triples; analysts see AI investments paying off

The U.S. stock market swung between gains and losses on Friday as investors weighed a surge in Amazon.com shares against a decline in Apple and the impact of rising oil prices on inflation. The S&P 500 index rose 0.6%, the Dow Jones Industrial Average added 0.5%, and the Nasdaq composite gained 0.8%, according to early afternoon trading data.

Amazon jumped 14.9% after reporting quarterly profit that more than tripled from the prior year, driven partly by an acceleration in its cloud computing business. Analysts said the results could indicate that Amazon’s extensive investments in artificial intelligence are beginning to generate returns. The company also increased its forecast for capital spending this year, signaling continued heavy investment in technology.

Apple shares declined, weighing on the market. The specific reason for the decline was not detailed in the report.

Rising oil prices added to worries about inflation, which has been putting pressure on the bond market. The combination of factors contributed to the choppy session, with the Dow up 282 points, or 0.5%, as of 1:44 p.m. Eastern time.