Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


ID DIVISION.
PROGRAM-ID. PLO.
DATA DIVISION.
WORKING-STORAGE SECTION.
01 VAR1 PIC 9(2).
01 VAR2 PIC X(2).
PROCEDURE DIVISION.
ACCEPT VAR2.
MOVE VAR2 TO VAR1.
STOP RUN.

if i give 'PI' in var2 then what will b output of progr.
any abend?????

Answers were Sorted based on User's Feedback



ID DIVISION. PROGRAM-ID. PLO. DATA DIVISION. WORKING-STORAGE ..

Answer / giri12

SOC7

Is This Answer Correct ?    13 Yes 0 No

ID DIVISION. PROGRAM-ID. PLO. DATA DIVISION. WORKING-STORAGE ..

Answer / dharma

U will not get SOC7 . but u will get unpredicatble results

Is This Answer Correct ?    3 Yes 0 No

ID DIVISION. PROGRAM-ID. PLO. DATA DIVISION. WORKING-STORAGE ..

Answer / dev

ABEND=S000 U4038 REASON=00000001. I have tested the program.

Is This Answer Correct ?    3 Yes 1 No

ID DIVISION. PROGRAM-ID. PLO. DATA DIVISION. WORKING-STORAGE ..

Answer / mdvasanth86

SOC 7 only when you do some arithmetic operation on it...
Displaying it will probably only give you unpredictable results.

HTH

Is This Answer Correct ?    2 Yes 0 No

ID DIVISION. PROGRAM-ID. PLO. DATA DIVISION. WORKING-STORAGE ..

Answer / piyush mani

i know soc7 abend should b the result but if i display var1 then program is running without any abend and output of program is absurd so i asked this question..

Is This Answer Correct ?    1 Yes 0 No

ID DIVISION. PROGRAM-ID. PLO. DATA DIVISION. WORKING-STORAGE ..

Answer / dimpy19

No abend
but unpredictable result

WORKING-STORAGE SECTION.
01 VAR1 PIC 9(2).
01 VAR2 PIC X(2).
PROCEDURE DIVISION.
ACCEPT VAR2.
MOVE VAR2 TO VAR1.
DISPLAY VAR1.
DISPLAY VAR2.
STOP RUN.


//STEP02 EXEC PGM=COB7
//STEPLIB DD DSN=DEA.SIQAGH.LOAD,DISP=SHR
//SYSPRINT DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SYSIN DD *
PI
/*



output
P9
PI

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More COBOL Interview Questions

suppose there is one PF having two members PF1 PF2.PF has one unique key Emp ID.could you tell me uniqueness in PF will be effective across members as well ? assume emp iD 3333 is in member PF1 would same Emp id be exist also in member PF2 ?

2 Answers   Tesco HSC, Wipro,


The following entries appear in the WORKING-STORAGE SECTION: 01 DATE-TODAY. 05 YY PIC XX VALUE "90". 05 MM PIC XX VALUE "12". 05 DD PIC XX VALUE :31". 01 DATE-EDIT PIC XX/XX/XX. MOVE DATE-TODAY TO DATE-EDIT. (a) 901231 (b) 90/12/31 (c) 31/12/90 (d) 311290

4 Answers   TCS,


Explain about Redefines cluse?

3 Answers   iGate,


If you were passing a table via linkage, which is preferable - a subscript or an index?

3 Answers   TCS,


Differentiate cobol and cobol-ii. (Most of our programs are written in cobolii, so, it is good to know, how, this is different from cobol)?

0 Answers  


Can we move SPACES to numeric field and ZEROES to alphabetic field? If yes what are the way doing this?

6 Answers   T systems,


What is tne need to use sub programs in Cobol?

3 Answers   HSBC,


how many bytes does a s9(12)COMP-4 field occupy?? a.2 b.4 c.8 d.1 ans with reason please

2 Answers  


how to convert vsam table into DB2 table?

1 Answers   IBM, Wipro,


which is better either static call or dynamic call? and why?

5 Answers   HCL,


What is the difference between Structured COBOL Programming and Object Oriented COBOL programming?

0 Answers   TryTechnicals Pvt Ltd,


can I copy book which contain db2 statment in procedure divion?

2 Answers   Bank Of America,


Categories