Exercise 1.5.5
ε-greedy: time steps where exploration definitely or possibly occurred
Consider a \(k\)-armed bandit problem with \(k = 4\) actions, denoted \(1\), \(2\), \(3\), and \(4\). Consider applying to this problem a bandit algorithm using \(\epsilon\)-greedy action selection, sample-average action-value estimates, and initial estimates of \(Q_1(a) = 0\), for all \(a\). Suppose the initial sequence of actions and rewards is \(A_1 = 3, R_1 =2, A_2 = 2, R_2 = 1, A_3 = 3, R_3 = -1, A_4 = 3, R_4 = 1, A_5 = 1, R_5 = 3\). On some of these time steps the \(\epsilon\) case may have occurred, causing an action to be selected at random. On which time steps did this definitely occur? On which time steps could this possibly have occurred?
Adapted from Sutton & Barto (2018), Reinforcement Learning: An Introduction, 2nd ed., Exercise 2.2. Licensed CC BY-NC-ND 2.0.