Alphabet Inc. and Amazon.com Inc. were rewarded by investors for reporting better-than-expected third-quarter profits. At both companies, earnings were boosted by the increased value of their stakes in Anthropic PBC, maker of the popular Claude chatbot.

