#!/usr/bin/python # -*- coding: utf-8 -*- # † # (ΦωΦ)<運を天にまかせる系 from datetime import datetime, timedelta from random import randint start = datetime.now() limit = timedelta(milliseconds=4949) n = int(raw_input()) k = int(raw_input()) turn, win = 0, 0 for _ in xrange(19921223): turn += 1 taro = sum(randint(1, 6) for _ in xrange(n-k)) \ + sum(randint(4, 6) for _ in xrange(k)) jiro = sum(randint(1, 6) for _ in xrange(n)) if taro > jiro: win += 1 now = datetime.now() if (now - start) >= limit: break print float(win) / turn