INSPECT TALLYING FOR LEADING SPACES The following COBOL program depicts the use of INSPECT TALLYING FOR LEADING SPACES 01 TEST-STRING PIC X(40) VALUE SPACES. 01 WS-COUNTER PIC 9(9) VALUE ZEROES. 01 SEARCH-STRING PIC X(2) VALUE SPACES. MOVE ‘ THIS IS TEST STRING TO TEST LEADING SPACES’ INSPECT TEST-STRING TALLYING WS-COUNTER FOR DISPLAY ‘COUNT OF LEADING SPACES IS = ‘ The output of the program is COUNT OF LEADING SPACES IS = 000000005