Creating a sublist of the positions of a value in a list

If I have a list [1,3,7,5,3,7,2,7] and I put it into a function with the 7, I would get a list [3,6,8], since there is a 7 in spots 3, 6, and 8. How do I do this?

Here you go. You can sort lists using criteria/restrictions. I did it as a function as well, so you can check for whichever values you like:

It appears I was overthinking the solution. I was expecting the solution to be way more complex.