Who can help me to complete there cobol execises



Support for OS/VS COBOL, VS COBOL II, COBOL for OS/390 & VM and Enterprise COBOL for z/OS

Who can help me to complete there cobol execises

Postby Trenfen » Sun Mar 07, 2010 2:49 pm

Exercise 1
Code a program named ‘tsoid01’ in ‘tsoid.TRAIN.PDS’
ACCEPT a text from SYSIN to 4 characters;
judge this text is numeric or not;
if it is a numeric text, then divide by 2, then display ‘result is’ quotient and ‘remainder is’ remainder;
if it is not a numeric text, then display ‘it is not a correct number’ with the text

Data Preparation
Allocate a PS dataset named ‘tsoid.INPUT.PS’ (record format is fixed-length, record length is 10)

Add records to this PS file as the following:
A ABADAEA
A ASDFJAJ
B ADFQWB
C IOQWEA
A CQWOE
B ASPQOE
C OEUWCO

Exercise 2
Code a program named ‘tsoid02’ in ‘tsoid.TRAIN.PDS’
read the file ‘tsoid.INPUT.PS’
Do the following process:
If start char is ‘A’, calculate the A numbers in the string
If B, calculate the B numbers
If C, calculate the C numbers
Then write the number and ‘A’ or ‘B’ or ‘C’ to the tables
Search a item which the number is 4
Firstly display all contents of the table, then display the index of the item which the number is 4

If you would like to help me then show me the codes please , thank you!
Trenfen
 
Posts: 7
Joined: Sun Mar 07, 2010 2:30 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Who can help me to complete there cobol execises

Postby dick scherrer » Sun Mar 07, 2010 9:56 pm

Hello and welcome to the forum,

If you would like to help me then show me the codes please
That is NOT help. . . That is doing the work for you. We won't do the work for you. We will HELP you get the work done.

If anyone posts complete code, it will be deleted.

What have you coded for exercise 1? Where are you stuck? If we are to help, you must show "where you are".
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Who can help me to complete there cobol execises

Postby Trenfen » Mon Mar 08, 2010 1:28 pm

I have already completed by myself , thanks for your reply.
Trenfen
 
Posts: 7
Joined: Sun Mar 07, 2010 2:30 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Who can help me to complete there cobol execises

Postby dick scherrer » Tue Mar 09, 2010 1:27 am

You're welcome - good to hear it is working :)

d
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times


Return to IBM Cobol

 


  • Related topics
    Replies
    Views
    Last post