      IDENTIFICATION DIVISION.
      PROGRAM-ID. 101B.
      DATA DIVISION.
      WORKING-STORAGE SECTION.
      01  INP PIC X(100).
      01  N   PIC 9(10).
      01  S.
      	03 SN PIC 9(1) OCCURS 10 TIMES.
      01 IDX  PIC 9(2).
      01 WA   PIC 9(10).
      01 SHO  PIC 9(10).
      01 AMA  PIC 9(10).
      
      PROCEDURE DIVISION.
      ACCEPT INP.
      MOVE INP TO N.
      MOVE INP TO S.
      
      PERFORM VARYING IDX FROM 1 BY 1 UNTIL (IDX > 10) OR (SN(IDX) = SPACE)
      ADD SN(IDX) TO WA
      END-PERFORM.
      
      DIVIDE N BY WA GIVING SHO REMAINDER AMA.
      
      IF AMA = 0
         DISPLAY "Yes"
      ELSE
      	 DISPLAY "No"
      END-IF.
      
      STOP RUN.