Question: Choosing elements of a sequence based on a condition


This is my first post here and I am really hoping someone can help me. I just started using Maple and I am using Maple 2021.

I generated numbers using a SEQUENCE and the sequence is called y. I am trying to extract the element (y[n]) and the index (n) of that element based on the CONDITION that y[n] has to lie in between 0 and 1 exclusive (so the element of the sequence or y[n] has to be such that 0 < y[n] < 1). How can I achieve this using select commad and also using a LOOP. Are there any other methods that can be used to achive this result. Any or all help would be really appreciated.


Thank you all.

Please Wait...