You can convert the set to a list and then use index to access an element from the set.
The set data structure does not care about the position of an element and that's why indexing is not supported. E.g.
- if you added you elements in the above order, it will be stored like the following. So, your input order is no more there and if you want to access elements as per your order, you will get the wrong element.
set([1, 2, 3, 4, 5, 6, 7, 8, 10])