Series: Subject: Topic:
Question: 120 of 233

What is difference between Initialize and value?

Asked by: Interview Candidate | Asked on: Aug 30th, 2006
Showing Answers 1 - 6 of 6 Answers
Shashank Kapoor

Answered On : Sep 1st, 2006

Value will initialize values in variables at the time of declaration.Whereas in Initialize value get initialize in procedure division. Initialize spaces in alphabhetic & in alphanumeric. Zeros in numeric.

Yes  3 Users have rated as useful.
Login to rate this answer.

Answered On : Sep 21st, 2006

value clause is used to initialize working storage variable.initialize clause is used in procedure division to initialize record, since its not possible to initilalize them at fd level.

Login to rate this answer.

Answered On : Oct 9th, 2006

value clause is used to initialize variables in the working-storage section.initialize is also used to initialize the variables.its more efficient to use initialize clause for initialising some variables such as file-status  etc.bcoz whenever an operation is performed related to files (such as file opening, reading a file..) ,we check for the status variable to know whether that step is performed successfully or not.if these variable is initialized with initialize clase, each time when a new record is going to be read, the file status varible is initializd with the initial value.which is not possible with value clause.

Yes  1 User has rated as useful.
Login to rate this answer.

Answered On : Nov 20th, 2006

value--- value is used to initialize data item in working storage sectionwhere as intialize----is used to initialize data item in procedure division

Yes  1 User has rated as useful.
Login to rate this answer.

Answered On : Jul 27th, 2011

View all answers by talluri

INITIALIZE verb is used to refresh the alphabetic & alphanumeric empty fields with SPACES and numeric empty fields with ZEROS

Login to rate this answer.

Answered On : Apr 30th, 2013

Value : value clause is used to initialize values at working storage section only.

i.e.., giving the values at declaration time initialize : this verb is used in 2 ways.

1) used to supply the initial values to numeric and zeros to numeric and spaces to alphanumeric at a time.

2) used to replace character or string to alphanumeric and numbers to numeric but it is not recommended.

Login to rate this answer.

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

Related Open Questions



twitter fb Linkedin GPlus RSS


Interview Question

 Ask Interview Question?


Latest Questions

Interview & Career Tips

Get invaluable Interview and Career Tips delivered directly to your inbox. Get your news alert set up today, Once you confirm your Email subscription, you will be able to download Job Inteview Questions Ebook . Please contact me if you there is any issue with the download.