The below Python code simulate the Game , we used to play in childhood days.... where we take a book and just open some random page and take last digit of page number as our score.... 

import random
def book_crick():
    total = 0
    Player_name = input("please Enter your name ")
    score = 1
    while(score != 0):
        num1 = random.randint(1,300)
        score = num1 % 10
        if(score > 6):
            score = 6
        print(score)
        total = total + score
    print("total score of " + Player_name,total)
def start_Play():
    print("Lets start the book cricker")
    book_crick()
    replay = input('do you want to play again ? Enter yes or no').lower().startswith('y')
    while(replay == True):
        book_crick()
        replay = input('do you want to play again ? Enter yes or no').lower().startswith('y')
    else:
        print("The End")

Comments