摘要 |
PURPOSE:To simply form a list using a list having the same format as an element by defining a structure corresponding to a list element. CONSTITUTION:A process P1 defines a structure 12 corresponding to list elements in a list 10 to be formed. A process P2 sets up the leading address of a list forming area 14 on a pointer ptr for the structure on the basis of a pointer setting sentence 13. A process P3 forms respective list elements by substituting prescribed values for a pointer variable and a data variable by using the structure 12. A process 4 counts up the pointer ptr for the structure 12 only by one element. The processes P3, P4 are repeated until the end of the formation of the final list element to form the list elements successively.
|