An advertisement for Samsung Electronics Co. Galaxy smartphones is displayed atop a building in the company's mobile business factory in Gumi, South Korea, on Sunday, April 5, 2020.

South Korean tech giant Samsung said Tuesday its operating profit for the three months that ended in March likely rose from a year ago and beat expectations slightly.

Samsung said it expects 6.4 trillion Korean won ($5.23 billion) in first-quarter operating profit for 2020, up 2.7% from the 6.23 trillion won it posted for the same period a year earlier. Analysts predicted Samsung to estimate its operating profit for the quarter to be 6.2 trillion ($5.05 billion) won, according to Refinitiv SmartEstimate, Reuters reported.

The company said it expects first-quarter consolidated sales of 55 trillion won, up almost 5% from a year ago.

Samsung shares rose 1.85% on Tuesday. It is one of the first major tech companies to report earnings estimates for the January-March quarter in the middle of the coronavirus pandemic.

The virus outbreak has led to growing concerns over demand for smartphones and other consumer electronics. Temporary closure of some Samsung factories and retail stores around the world is likely going to have an impact on sales. The company did not break down the operating profit and consolidated sales numbers for each of its business units in Tuesday's guidance.

But a relatively weak Korean won, cost-saving efforts and strong demand for memory chips are set to drive the company's earnings, according to SK Kim, executive director and analyst at Daiwa Securities.

He explained on CNBC's "Squawk Box" that the virus outbreak has pushed more people to work from home and make their purchases online. That is boosting demand for memory chips from data centers, which they support a variety of internet services.

"This will continue to drive memory price high in the second quarter, which will offset weakness on the mobile as well as the TV (business)," Kim said.