Stocks ended mixed on Thursday as investors weighed dismal earnings from chip gear giant Applied Materials against a string of good news from Afghanistan and a steady drop in oil prices. 

The Dow Jones industrial average gained 48.78 points, or 0.50 percent, to end the day at 9,872.39, while the technology-laced Nasdaq Composite Index slipped 2.53 points, or 0.13 percent, at 1,900.66. The broader Standard & Poor's 500 Index edged up 1.05 points, or 0.09 percent, to 1,142.26.

"People continue to get a little bit more optimistic every day as long as we don't get bad economic data, or earnings or some terrorist attack or this Afghanistan thing suddenly turns," said Uri Landesman, chief investment officer with AFA Management Partners.

Applied Materials dropped $1.62, or 4 percent to $39.09 after its profits sank 97 percent, but other chip stocks held steady. Oil stocks continued to slide as crude oil prices slumped again amid squabbles between the Organization of Petroleum Exporting Countries and its rivals over oil-output curbs.

Airline and hotel stocks rose, rebounding after Monday's plane crash in New York. UAL Corp. climbed after its unit United Airlines said it will become the first major U.S. airline to install stun guns on every aircraft in its fleet following the Sept. 11 attacks on the United States.

The technology-laden Nasdaq has racked up a gain of more than 4 percent this week, while the blue-chip Dow has snagged an increase of more than 2 percent. Hopes for an economic snapback next year, fueled by sharp interest-rate cuts and a hefty government stimulus package, have lifted stocks well off lows hit after Sept. 11. 

"Obviously, we had a great week so far, and we are consolidating some gains and Applied Materials is putting a little bit of a damper on the market," said John Forelli, senior vice president at Independence Investment LLC, which oversees $20 billion. "But investors are starting to get confident that we are not going to retest the old lows."

Eastman Kodak Co. jumped $1.34 to $28.62, its 4.9 percent gain contributing a big chunk of the rise in the blue-chip Dow. The photography giant will realign its operations to cut spending and boost lagging profits.

Exxon Mobil Corp., the No. 1 U.S. oil company and a Dow stock, fell $1.51 to $37.19. Oil prices sank after OPEC raised the stakes in a game of high-risk poker with rival oil producers. The market reacted sharply to remarks from Kuwait's oil minister expressing opposition to OPEC output cuts without non-OPEC cooperation.

The Philadelphia oil services index sank 10.59 percent, reflecting weakness in companies like Schlumberger Ltd. , down $2.92 to $43.18.

Wall Street took heart from news of more progress in the U.S.-led campaign in Afghanistan. Washington said it was "tightening the noose" around Osama bin Laden in Afghanistan, as thousands of his Arab troops and Taliban protectors were surrounded in the northern city of Kunduz, facing a fight to the death.

But pundits also warned that as far as the market is concerned, it will be back to Square One, once the enthusiasm for bombing the Taliban wears off.

"Hopefully, we will hang bin Laden from the nearest lamp post. But then you've got to go back to fundamentals," said Jon Brorson, director of equities at Northern Trust Fund, which oversees $330 billion. "The economy is still pretty sluggish ... we are looking for a sluggish upturn and you have the earnings situation. It will be back to reality."

Wall Street's largest brokerage houses fell on concerns strength in their stocks had outpaced their profit outlooks. The SEC Broker-Dealer index fell 2.34 percent. The index has risen more than 46 percent since hitting a recent trough of 336.17 in the aftermath of the Sept. 11 attacks.

"We have been going like a house on fire," said Larry Wachtel of Prudential Securities. "There is good news in terms of the military, and the price of oil falling constitutes a tax cut for consumers. All these things are wonderful, but we are now overbought."

Dow component International Business Machines Corp. rose 40 cents to $114.75. The No. 1 computer maker said while demand for new technology products may be waning, its industry-leading services business has picked up the slack.

In the latest economic data, manufacturing activity in the U.S. mid-Atlantic region contracted for the 12th month in a row in November, but the pace of deceleration slowed, according to a survey released by the Federal Reserve Bank of Philadelphia.

Earlier, Washington said the number of Americans filing weekly jobless claims dropped unexpectedly for the third straight week, but the number of workers staying unemployed was up 18 percent since early September.

Declining issues barely outnumbered advancers 16 to 15 on the New York Stock Exchange. Volume came to 1.45 billion shares, compared with the 1.43 billion traded Wednesday. 

The Russell 2000 index, the barometer of smaller company stocks, fell 3.43, or 0.8 percent, to 449.39. 

Overseas, markets were mixed Thursday. Japan's Nikkei stock average registered its best finish in three months, soaring 4 percent. Analysts attributed the run-up to the rallies in New York and expectations that the war in Afghanistan could end soon following a string of victories by the Northern Alliance. 

France's CAC-40 and Britain's FT-SE 100 each closed down nearly 0.1 percent, while Germany's DAX index rose 1.1 percent.

Reuters and the Associated Press contributed to this report.