EXHIBIT 5


                                   May 8, 2000

International Business Machines Corporation
New Orchard Road
Armonk, New York 10504

Ladies and Gentlemen:

I am a Vice President and Assistant General Counsel of International Business
Machines Corporation (herein called the "Corporation") and an attorney duly
admitted to practice in the State of New York. I am familiar with the
Registration Statement on Form S-8 (the "Registration Statement") under the
Securities Act of 1933 (the "Securities Act") regarding the 30,000,000 shares of
common stock, par value $.20 per share, of the Corporation (the "Shares") to be
issued pursuant to the IBM 2000 Employees Stock Purchase Plan (the "Plan").

I, together with competent members of my legal staff working under my direct
supervision and control, have reviewed such documents and records as I have
deemed necessary or appropriate to enable me to express an informed opinion with
respect to the matters covered hereby.

Based upon the foregoing, I am of the opinion that, when issued or sold in
accordance with the terms of the Plan, the Shares will be validly issued, fully
paid and nonassessable.

I hereby consent to the use of my name in the Registration Statement as the
legal counsel who has passed upon the legality of the Shares, as well as to the
use of this legal opinion as part of the Registration Statement, as required by
Section 7 of the Securities Act, as amended.

                     Very truly yours,

                     /s/ DAVID S. HERSHBERG
                     ----------------------
                     David S. Hershberg
                     Vice President and
                     Assistant General Counsel