View previous topic :: View next topic |
Author |
Message |
js01 Beginner
Joined: 13 Oct 2005 Posts: 84 Topics: 32 Location: INDIA
|
Posted: Thu Mar 26, 2009 5:11 pm Post subject: ROUNDED in cobol |
|
|
Hello friends,
could you please help me in below question
declared
05 VAR1 S9(5)V99
05 VAR2 S9(5)V99 value 2070
Compute VAR1 ROUNDED = VAR2 * 1.4
what is the value of VAR1
thank you |
|
Back to top |
|
 |
kolusu Site Admin

Joined: 26 Nov 2002 Posts: 12378 Topics: 75 Location: San Jose
|
Posted: Thu Mar 26, 2009 6:40 pm Post subject: |
|
|
js01,
What makes you think posting it as separate topic would get you the answer? . Either way unless this is a trick question , VAR1 would have 2898. 00 (untested)
Why is this even a question in the first place.
Kolusu _________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
 |
Anuj Dhawan Intermediate
Joined: 19 Jul 2007 Posts: 298 Topics: 7 Location: Mumbai,India
|
Posted: Fri Mar 27, 2009 6:28 am Post subject: |
|
|
Hi,
What happened when you try this at your end? May be if you try the code with or with out ROUNDED you get a better understanding. _________________ Regards,
Anuj |
|
Back to top |
|
 |
js01 Beginner
Joined: 13 Oct 2005 Posts: 84 Topics: 32 Location: INDIA
|
Posted: Fri Mar 27, 2009 9:39 am Post subject: |
|
|
Kolusu/Anju,
Thanks for your qucik repsonce,
the above login in one of our program and the result is 1739 , i'm not able to undetsand why this value is getting? ...the value should be 2898
could you please explain |
|
Back to top |
|
 |
Anuj Dhawan Intermediate
Joined: 19 Jul 2007 Posts: 298 Topics: 7 Location: Mumbai,India
|
Posted: Sat Mar 28, 2009 10:29 pm Post subject: |
|
|
Quote: | the above login in one of our program and the result is 1739 , i'm not able to undetsand why this value is getting? ...the value should be 2898 | Information which we have in hand so far does not give any clue why would this haapen. Please show us the "actual code" used in that program . . .
I'm Anuj by the way . . . _________________ Regards,
Anuj |
|
Back to top |
|
 |
|
|