Shares of the company, formed out of the 2015 split of Hewlett-Packard Co, were, however, down 3 percent in after-market trading in low volumes.

Susquehanna analyst David Ryzhik attributed the weakness in shares to disappointing margins at the company's printer business.

Investors had expected to see sequential increase in margins following the acquisition of Samsung's printer business late last year, Ryzhik said.

"Their printing business operating margins were underwhelming."

Margins at the business fell for the third straight quarter, while revenue from the segment rose about 11 percent to $5.19 billion, above analysts' estimate of $5.11 billion.

HP Inc's personal systems business, which includes desktops and notebooks and accounts for more than 60 percent of total revenue, rose 12 percent to $9.4 billion, beating analysts' average estimate of $9.06 billion, according to Thomson Reuters I/B/E/S.

The Palo Alto, California-based company had the top position in worldwide PC shipments in the second quarter with a 23.9 percent market share, according to research firm International Data Corp's data.

HP Inc raised its forecast for full-year adjusted profit to between $2 and $2.03 per share, from $1.97 and $2.02 per share earlier. Analysts on average were expecting $2, according to Thomson Reuters I/B/E/S.

Excluding items, HP Inc reported a profit of 52 cents per share for the third quarter ended July 31, one cent above the average analyst estimate.

Net revenue rose about 12 percent to $14.59 billion.

Analysts on average had expected revenue of $14.27 billion.

(Reporting by Akanksha Rana in Bengaluru; Editing by Sriraj Kalluvila)