#include <bits/stdc++.h>
using namespace std;
const int MAXN = 256;
const int MAXT = 230;
double dp[205][2][MAXT][MAXN];
int cal(int j) {
  int cnt = 0;
  if (j == 0) return 0;
  while (j % 2 == 0) {
    cnt++;
    j /= 2;
  }
  return cnt;
}
int main() {
  int x, k, p;
  while (~scanf("%d %d %d", &x, &k, &p)) {
    double pb2 = (double)p / 100.0;
    double pb1 = 1.0 - pb2;
    for (int i = 0; i <= k; i++)
      for (int t = 0; t < 2; t++)
        for (int j = 0; j < MAXT; j++)
          for (int m = 0; m < MAXN; m++) dp[i][t][j][m] = 0.0;
    int rem = x % 256;
    if (rem) {
      x /= 256;
      int cnt = 0;
      while (x & 1) {
        x >>= 1;
        cnt++;
      }
      dp[0][1][cnt][rem] = 1.0;
    } else {
      int cnt = 0;
      while (x % 2 == 0) {
        x /= 2;
        cnt++;
      }
      dp[0][0][cnt - 7][0] = 1.0;
    }
    for (int i = 0; i < k; i++)
      for (int t = 0; t < 2; t++)
        for (int j = 0; j < 230; j++)
          for (int m = 0; m < MAXN; m++) {
            double cur = dp[i][t][j][m];
            if (t == 0) {
              dp[i + 1][t][j + 1][m] += cur * pb2;
              dp[i + 1][1][0][1] += cur * pb1;
              break;
            } else {
              if (j >= 200) break;
              if (m == 128)
                dp[i + 1][0][1][0] += cur * pb2;
              else if (m > 128)
                dp[i + 1][t][j + 1][(m * 2 - 256)] += cur * pb2;
              else if (m == 0 && j)
                dp[i + 1][0][2][0] += cur * pb2;
              else
                dp[i + 1][t][0][m * 2] += cur * pb2;
              if (m == 255)
                dp[i + 1][0][j + 1][0] += cur * pb1;
              else
                dp[i + 1][t][j][m + 1] += cur * pb1;
            }
          }
    double ans = 0.0;
    for (int t = 0; t < 2; t++)
      for (int j = 0; j < MAXT; j++) {
        if (t == 0 && j) {
          ans += dp[k][t][j][0] * (j + 7);
        } else {
          for (int m = 1; m < MAXN; m++) {
            ans += dp[k][t][j][m] * cal(m);
          }
        }
      }
    printf("%.13lf\n", ans);
  }
  return 0;
}
