update Code book