Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Cobol Interview Questions

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions
View previous topic :: :: View next topic  
Author Message
philipraju
Warnings : 1

New User


Joined: 16 Apr 2006
Posts: 29

PostPosted: Sun Jun 18, 2006 10:47 pm    Post subject: Cobol Interview Questions
Reply with quote

Hi,

Can any body gives answers of below questions....
1.How many time "philip " displays
para-a
Perfoem para-b until x>10
para-b
display "philip"
Exit
2..How many time "philip " displays
para-a
Perfoem para-b until x>10
para-b
display "philip"
continue
3.How many time "philip " displays
para-a
Perfoem para-b until x>10
para-b
display "philip"
stop run
4.How many time "philip " displays
para-a
Perfoem para-b until x>10
para-b
display "philip"
next setntence


5.regarding DISP parameter

disp=new to already created DS,what will happens,
disp=old to not created DS,what will happens,
disp=shr to does not existed DS,what will happens,
Back to top
View user's profile Send private message

khamarutheen

Active Member


Joined: 23 Aug 2005
Posts: 680
Location: NJ

PostPosted: Mon Jun 19, 2006 1:29 pm    Post subject: Interview Question
Reply with quote

Quote:
1.How many time "philip " displays
para-a
Perfoem para-b until x>10
para-b
display "philip"
Exit


Ans : It's infinity since value of x is not incremented any where....

Quote:

2..How many time "philip " displays
para-a
Perfoem para-b until x>10
para-b
display "philip"
continue


Ans: It's also infinity times.

Quote:

3.How many time "philip " displays
para-a
Perfoem para-b until x>10
para-b
display "philip"
stop run


Ans : 1 Time since at stop run the program ends.

Quote:

4.How many time "philip " displays
para-a
Perfoem para-b until x>10
para-b
display "philip"
next setntence


Ans : Infinity.
Back to top
View user's profile Send private message
Rupesh.Kothari

Member of the Month


Joined: 27 Apr 2005
Posts: 464

PostPosted: Mon Jun 19, 2006 1:40 pm    Post subject: Re: Cobol Interview Questions
Reply with quote

Hi,

Quote:
5.regarding DISP parameter

disp=new to already created DS,what will happens,
disp=old to not created DS,what will happens,
disp=shr to does not existed DS,what will happens,


In all the case job will abended saying JCL error.

HTH

Regards
Rupesh
Back to top
View user's profile Send private message
philipraju
Warnings : 1

New User


Joined: 16 Apr 2006
Posts: 29

PostPosted: Mon Jun 19, 2006 1:53 pm    Post subject: Hi khamarutheen,
Reply with quote

if the value of x=11,what will be the output in these conditions
Back to top
View user's profile Send private message
philipraju
Warnings : 1

New User


Joined: 16 Apr 2006
Posts: 29

PostPosted: Mon Jun 19, 2006 1:55 pm    Post subject: Hi Rupesh.Kothari,
Reply with quote

Can u gives the details of the abend JCl error codes
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1187
Location: Bangalore,India

PostPosted: Mon Jun 19, 2006 2:25 pm    Post subject:
Reply with quote

Hi philipraju

If x=11 in that case for all 4 condition it wont satisfy the condition hence
philip won't display at all
Back to top
View user's profile Send private message
khamarutheen

Active Member


Joined: 23 Aug 2005
Posts: 680
Location: NJ

PostPosted: Mon Jun 19, 2006 2:46 pm    Post subject:
Reply with quote

Philip,

Quote:
Can u gives the details of the abend JCl error codes


Please download our product Error Descriptor and check it out.

Quote:

if the value of x=11,what will be the output in these conditions


Where you are meaning the value. R u saying in condition. If so the value of x is not assigned or initialized anywhere then how can we get the value in the condition at x=11. If so you assign in para2 x=11, 11>10 it will satisfy . Till the value of x is incremented the condition will not met.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. Full Time COBOL Software Development ... shally Mainframe Jobs 0 Fri Jan 20, 2017 5:24 am
This topic is locked: you cannot edit posts or make replies. COBOL Software Development Lead at Fi... shally Mainframe Jobs 0 Fri Jan 20, 2017 5:21 am
No new posts Executing OO COBOL program invoking J... Virendra Shambharkar COBOL Programming 2 Tue Jan 10, 2017 6:37 pm
No new posts OO COBOL compile error Virendra Shambharkar COBOL Programming 3 Tue Jan 10, 2017 6:05 pm
No new posts Need Suggestion on COBOL program vickey_dw COBOL Programming 5 Thu Jan 05, 2017 10:55 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us