IDENTIFICATION DIVISION.
PROGRAM-ID. EXAMPLE-OOP.
AUTHOR. YOUR NAME.

DATA DIVISION.
CLASS-ID. STUDENT.
DATA SECTION.
01 NAME PIC X(20).
01 AGE PIC 9(3).
01 GPA PIC 9V99.
01 STUDENT-STATUS PIC X(1).
01 STUDENT-TYPE PIC X(1).

METHOD-ID. SET-STATUS.
PROCEDURE DIVISION.
   SET STUDENT-STATUS TO "A".
END METHOD.

END CLASS.

PROCEDURE DIVISION.
   SET STUDENT-STATUS TO "E".
   SET OBJ-STUDENT TO NEW STUDENT.
   SET NAME OF OBJ-STUDENT TO "John Smith".
   SET AGE OF OBJ-STUDENT TO 20.
   SET GPA OF OBJ-STUDENT TO 3.8.
   INVOKE OBJ-STUDENT SET-STATUS.
   DISPLAY NAME OF OBJ-STUDENT "is a(n)" STUDENT-TYPE "student with a GPA of" GPA OF OBJ-STUDENT.
STOP RUN.
