View previous topic :: View next topic
|
Author |
Message |
ritesh pandey
New User
Joined: 09 Feb 2007 Posts: 11 Location: Pune
|
|
|
|
Can we use '%' operator in COBOL ,like in C if yes Then how . |
|
Back to top |
|
|
agkshirsagar
Active Member
Joined: 27 Feb 2007 Posts: 691 Location: Earth
|
|
|
|
No. |
|
Back to top |
|
|
atosvv
New User
Joined: 04 Dec 2008 Posts: 11 Location: Mumbai
|
|
|
|
Hi Ritesh,
I think you are looking for the MOD operator (to obtain the remainder while performing division) equivalent in COBOL.
Please refer the DIVIDE ...... REMAINDER in COBOL.
DIVIDE A BY B GIVING C REMAINDER D.
Keep Learning.
-VV |
|
Back to top |
|
|
agkshirsagar
Active Member
Joined: 27 Feb 2007 Posts: 691 Location: Earth
|
|
|
|
I thought like %d, %f in displays..
Never though it could be for mod operator.. Let's see what OP says on this. |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
Quote: |
I think you are looking for the MOD operator (to obtain the remainder while performing division) equivalent in COBOL.
Please refer the DIVIDE ...... REMAINDER in COBOL.
DIVIDE A BY B GIVING C REMAINDER D. |
and
Quote: |
I thought like %d, %f in displays..
Never though it could be for mod operator.. |
Another example of why it is so vital to be very clear and precise (and use the correct terminology) in the questions posed on this forum -- so frequently there are multiple interpretations to what is asked and additional clarification is required to answer the actual question, not the understood question. |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
By the way even I thought about mod operator, I was on the way back to Mumbai so could not reply.
-Ad |
|
Back to top |
|
|
|