You are working on a COBOL program that deals with financial transactions. Which COBOL data type would you choose to store currency amounts with two decimal places accurately?

  • PIC S9(11)V9(2) COMP
  • PIC S9(11)V9(2) COMP-3
  • PIC S9(13)V9(2) COMP
  • PIC S9(13)V9(2) COMP-3
The PIC S9(11)V9(2) COMP-3 data type in COBOL is suitable for storing currency amounts with two decimal places accurately. It represents a packed-decimal format, ensuring precise storage and manipulation of decimal values.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *