Write a program to display prime numbers between 1 to 100 using RPGLE.
D N S 2P 0 INZ 0
D Q S 2P 0
D R S 2P 0
D I S 2P 0
C PARM N
MOVE 2 I
DOU I >= N
I DIV N Q
MVR R
IF R=0
“Number is not PRIME” DSPLY
ENDIF
ADD 1 I
ENDDO
IF N=I
THEN
“Number is PRIME” DSPLY
ENDIF
C SETON LR
| Is This Answer Correct ? | 3 Yes | 2 No |
A rpg or clp command to find if the file field is defined as a character or numeric field.
RPG/400 faqs?
How can we call CL program to RPG? How many number of parameter we can pass
why we do STRSRVJOB in batch debugging in as400
1. If there are two programs using same file and 2 users are using the file at the same time and what can be done to allow them both to access? 2. How can remove lock from the file for accessing it by both users?
What is the syntax of passing parameters to a procedure by value?
How can you determine the number of characters in a variable?
What are the types of identifiers?
If there are 1000 member(PGM type) in a SRC file. How can we compile in a CL program? ( It need to be done in a loop)?
How can you delete records form a file in rpg without using "Delete" OPCODE?
am 2010 passed out . can any one tell me which course is good to put 2+fake .guide me
wat is the difference between array and multiple occurence data structure?