From the form of the function, its fairly clear that the appropriate subsequences are geometric with ratio 4 (iterate to an even index) or 1/2 (iterate to an odd index), so its shouldnt be that hard? Really for each index youre counting the number of odd and even iterations and noting that 2 odds and 1 even leave the number unchanged and having 2 more evens means its > 10 and youve a max of 5 iterations to get to 50.
So you could have straight 2,3,4,5 even maps corresponding to n=4,8,16,32. 4 or 3 even maps with 1 odd one, so n=24,48,20,40, ... With 2 odd ones, youd need to have 3 even so a few of those would not be valid and no 3 odd ones would be valid
Edit - a bit more systematic way of considering the odd/even maps would be to iterate out the even maps so n=2,4,8,16,32 and think about how to get the intermediate values. So consider n=17..31. n=16 is given by 4 iterations of the even map so f(16)=4^4=256. All the values from 17 to 31 will be given by 4 iterations of odd/even maps. 17 is eeeo, 18 is eeoe, 19 is eeoo, 20 is eoee, 21 is eoeo .... So really its just a binary pattern where you count the number of 1 and 0s and they determine whether e-o/2>=2 (for > 10). Or equivalently
n = 2,3
e,o = (1,0),(0,1)
n=4..7
e,o = (2,0),2*(1,1),(0,2)
n=8..15
e,o = (3,0),3*(2,1),3*(1,2),(0,3)
....