U.S. Steel Corp.'s third-quarter profit rose sharply from a year earlier, with steel operations accounting for nearly 40 percent of the improved results.

David Roderick, chairman of the nation's largest steel producer, said yesterday that the burgeoning energy markets were responsible for the company's third-quarter gains. But other product lines were hurt by the increase in what he asserted were unfairly priced imports and weak markets.

The company said net income for the quarter totaled $536.9 million ($6 a share) on sales of $3.5 billion. During the same period in 1980, net income totaled $77 million (88 cents) on sales of $2.8 billion.

Nine-month net income totaled $975.4 million ($10.97) on sales of $10.7 billion compared with 1980 nine-month net income of $314.5 million ($3.09) and sales of $9.1 billion.

Public steel shipments for the third quarter increased to 3.9 million tons from 3.6 million tons in the third quarter last year. Nine-month shipments rose to 13.3 million tons from 12.7 million tons in the comparable period in 1980.

International Telephone & Telegraph Corp. said yesterday that it had a net loss of $34.8 million in the third quarter due to foreign currency translation losses.

The third-quarter loss compared with a profit of $197.9 million ($1.35 a share) in the same quarter last year.

Revenues fell to $5.4 billion from $5.6 billion a year ago.

Nine-month net income totaled $274.4 million ($1.84) compared with $609 million ($4.17) in the comparable period last year. Foreign exchange losses reduced the nine-months results by $1.55 a share compared with a gain of 35 cents a share a year ago. Revenues dipped to $16.8 billion from $17 billion.

Sun Co., the nation's 11th-largest oil company, reported yesterday that its third-quarter profits rose 7.6 percent in the strongest showing since the second quarter last year.

Sun said its improved results reflected a 36 percent increase in U.S. exploration and production earnings and a rebound in domestic refining and marketing operations because of a decline in crude-oil costs.

In the quarter, Sun Co. earned $210 million ($1.73 a share), up from $195 million ($1.59) in the third quarter of 1980. Revenues advanced 23 percent to $3.7 billion from $3 billion.

Nine-month earnings were $628 million ($5.15), a decline of 9.4 percent from $693 million ($5.70) in the same period last year. Revenues rose 27 1/2 percent to $11.6 billion from $9.1 billion.

Eastern Airlines recorded a third-quarter loss almost doubled from that of a year earlier, and Chairman Frank Borman blamed the big deficit on the air traffic controllers strike and competitive cut-rate fares.

The loss was $38.7 million on revenues of $902.1 million compared with a loss of $22.3 million a year ago on revenues of $856.5 million.

The nine-month loss was $39.2 million on revenues of $2.33 billion compared with a loss of $34.7 million a year ago on revenues of $2.56 billion.