|
|
|
|
COBOL Lab Model Exam(for
BCA of M.G.University)
Posted by Sabu M K, M.E.S.College Marampally
on 24/06/2008 updated on 25/06/2008 |
Model
Questions: (Adobe Reader is required to
see the answers)
|
| Question
1: Write
a cobol program to create a Journal file
using the following transactions containing
the fields Date, Debit-account, Credit-account
and amount. Following are the transactions
of Mr. Kishore for the month of January.
m1cob |
2001
January |
|
1 |
Brought in
capital Rs.30,000. |
5 |
Purchased
goods from X for Rs.50, 000 on credit. |
5 |
Sold goods
for cash Rs. l5, 000. |
7 |
Sold goods
to Mr. Ram Rs. 25,000. |
9 |
Purchased
goods for cash Rs. l0,000. |
15 |
Insurance
paid Rs. 500. |
17 |
Cash withdrawn
for personal use Rs. l000. |
20 |
Paid electricity
charges Rs. 200. |
30 |
Salary paid
Rs.3,000. |
30 |
Rent paid
Rs. l000. |
| |
|
| Hint:
A sequential file named journal will have
to be created to store details in a journal
book in a double entry accounting system
with two example entries as shown below.
We are considering journal entries where
each entry affects only two accounts |
 |
Date
|
Particulars |
Debit
Amount |
Credit
Amount |
 |
01/01/2001 |
Cash
A/c Dr. |
5,000 |
|
| |
To
Furniture A/C |
|
5,000 |
| |
|
|
|
01/01/2001 |
Postage
A/c Dr. |
1,500 |
|
| |
To
Cash A/C |
|
|
 |
| The
structure of the journal file will be as
shown below where one record will be created
for each journal entry: |
Date |
: |
Date
of Transaction |
Debit-Account |
: |
Name
of account to be debited |
Credit-Account |
: |
Name
of account to be credited |
Amount |
: |
Amount
of Transaction |
| |
|
|
|
| For
example the above journal entry will add
a record in the file as follows: |
 |
Date |
Debit-Account |
Credit-Account |
Amount |
 |
01/01/08 |
Cash
A/C |
Furniture
A/C |
5,000 |
01/01/08 |
Postage
A/C |
Cash
A/C |
1,500 |
 |
|
| |
|
| |
|
|
| a) Total Debit
Amount |
: |
Amount total
in the Debit-Account Column |
| b) Total Credit Amount |
: |
Amount total in the Credit-Account
Column |
| c) Balance |
: |
Difference of Total Debit
Amount and Total Credit Amount |
| d) Debit Balance |
: |
Total Debit Amount –
Total Credit Amount if total debit exceeds
total Credit or 0 otherwise |
| e) Credit Balance |
: |
Total Credit Amount –
Total Debit Amount if total Credit Amount
exceeds total Debit amount or 0 otherwise |
|
| |
|
| |
|
| |
Question
5: Using
an existing sequential file containing Employee
Number, Name, Designation, Basic Pay, create
another sequential file named Salary which will
contain Employee No, Basic Pay, Dearness Allowance(50%
of Basic pay), HRA (10% of basic pay), TAX (0
for Basic<5000, 1% of basic otherwise), Gross
Pay (Basic Pay+Dearness Allowance + HRA), Net
Pay ( Gross Pay- Tax). m5.cob
input_file
|
|
| |
| |
| |
| |
|