Given the following code, what is the value of RESULT?

DName+++++++++++ETDsFrom+++To/L+++IDc.Keywords+++++++++++++
D RESULT S 5 0

C EVAL RESULT = (2 + 3 * 2) ** 2 / 2

Answers were Sorted based on User's Feedback



Given the following code, what is the value of RESULT? DName+++++++++++ETDsFrom+++To/L+++I..

Answer / anuj

Agreed.. Should be 32.. see below

1. RESULT = (2 + 3 * 2) ** 2 / 2
2. RESULT = (8) ** 2 / 2
3. RESULT = 64 / 2 = 32.

Thanks.

Is This Answer Correct ?    17 Yes 0 No

Given the following code, what is the value of RESULT? DName+++++++++++ETDsFrom+++To/L+++I..

Answer / prad

32

Is This Answer Correct ?    7 Yes 0 No

Post New Answer

More RPG400 Interview Questions

Hi guys, anybody know How RPG/400 code can be converted to RPG IV code with a single command?

1 Answers  


can we perform CHAIN operation on Subfile record format....?

4 Answers  


Suppose I have 3 jobs a b and c. I want to submit b after successful completion of a and want to submit c after successful completion of b. Without using job scheduler or job queue, how can I do that through cl program?

1 Answers  


1.find most occurrences of a character. for exm: input:aaabbbbdddddyyy output: d 5 times how can i get that?

13 Answers   HCL,


Need a sql query: retrive all duplicate records in table

3 Answers  






What will be the value of STRING after line 0106 is executed in the code below? 0101 E* Fromfiletofile..tabnameprnentlenpdatabnamlenpda 0102 E ARR 8 1 0103 ISTRING DS 0104 I 1 8 ARR 0105 C MOVE *BLANK STRING 0106 C MOVEA'ABC' ARR A) 'AAAAAAAA' B) 'BBBBBBBB' C) 'CCCCCCCC' D) 'ABC ' E) ' ABC'

2 Answers  


What is SFLNXTCHG keyword why it has used and where? Briefly explain with Example.

2 Answers   IBM,


what is importance of 'MAPFLD' IN OPNQRYF FILE ?

2 Answers  


What is the difference between copybooks and subprocedures in as400?

0 Answers  


1.What is referential Integrity? 2.What is Foreign Key? 3.What is Transfer Control? 4.What is Free format?

3 Answers  


What would be the result on writing a data record to a PF file using the "WRITE" opcode after the SETON *ON *INLR statment?

10 Answers  


Suppose we have one database file and it is used by 5 programs and in 3 program we have to add some records in datbase file s what is the impact on other program?

0 Answers  


Categories