Question
How can I write an iterator in a procedure? Sorry for my dump question, I am novoice. Thanks for the answers.
Solution
It totally depends on what you need to iterate over.
An array? Use a loop: plain, for, or while.
One of the predefined containers? Use the iterator declarations associated with the container.
A string? Treat it like an array.
It would help if you provided more specifics about what you're trying to accomplish.
OTHER TIPS
See the Ada style guide
You can check the Ada 95 Rationale. There is an example there of an iterator which you might use as a starting point. Look here: http://www.adahome.com/LRM/95/Rationale/rat95html/rat95-p2-3.html#7
Well, like others have said, it depends...
Personally, in my current project I find myself doing stuff like this quite a lot:
for Thing in 1..Number_Of_Things loop
-- do stuff here
end loop;