1. Suppose that a list contains the values 20 44 48 55 62 66 74 88 93 99 at index positions 0 through 9. Trace the values of the variables….

## Find a hypothesis class H and a sequence of examples on which Consistent makes |H|−1 mistakes.

1. Find a hypothesis class *H *and a sequence of examples on which Consistent makes |*H*|−1 mistakes.

2. Find a hypothesis class *H *and a sequence of examples on which the mistake bound the *Halving *algorithm is tight.

3. Let *d *≥ 2, *X *= {1*, . . .,**d*} and let *H *= {*h j *: *j *∈ [*d*]}, where *h j *(*x*) = 1[*x*=*j *]. Calculate *M*Halving(*H*) (i.e., derive lower and upper bounds on *M*Halving(*H*), and prove that they are equal).

4 The Doubling Trick:

In Theorem 21.15, the parameter *η *depends on the time horizon *T *. In this exercise we show how to get rid of this dependence by a simple trick. Consider an algorithm that enjoys a regret bound of the form *α* √\ *T *, but its

parameters require the knowledge of *T *. The doubling trick, described in the following, enables us to convert such an algorithm into an algorithm that does not need to know the time horizon. The idea is to divide the time into periods of increasing size and run the original algorithm on each period. The Doubling Trick

input: algorithm *A *whose parameters depend on the time horizon for *m *= 0*,*1*,*2*, . . .* run *A *on the 2*m *rounds *t *= 2*m**, . . .,*2*m*+1 −1 Show that if the regret of *A *on each period of 2*m *rounds is at most *α* √ 2*m*, then the total regret is at most