166
rbbbbbbbbbbbbrbrrbbrbbbrbbbbbbbbbbrbbbbbbrbbbrbbbbbrbbbbbbbrbbbbbbbrbbrbbbbbbbbrbbbbbbbbbbbbbbrrbbbrbbbbbbbbbbbbbbrbrbbbbbbbbbbbrbbbbbbbbbbbbbbrbbbbbbbbbbbbbbbbbbbbbb
 7
rrbrbrb
 1
r
 2
bb
 18
rrrrrrrrrrrrrrrrrb
 8
rbbrbrbr
 1
b
 13
rbbbrbrrbrrbb
 100
brbbbrrrbbrbrbbrbbrbbbbrbbrrbbbrrbbbbrbrbbbbbbbbbbbbbbbbrrrrbbbbrrrbbbbbbbrbrrbrbbbbrrrbbbbrbbrbbbrb
 2
rb
 2
rr
 2
br

70
 1
 0
 1
 8
 1
 0
 3
 34
 0
 1
 0

#include <bits/stdc++.h>
using namespace std;
short arr[200100];
int main() {
  long long n, t, x, id, after, i;
  string s, ans;
  cin >> n >> t >> s;
  x = 0;
  id = 0;
  while ((x < n) && (s[x] != '.')) {
    id++;
    arr[id] = int(s[x]) - int('0');
    x++;
  }
  after = id;
  x++;
  while ((x < n) && (int(s[x]) - int('0') < 5)) {
    id++;
    arr[id] = int(s[x]) - int('0');
    x++;
  }
  if ((t > 0) && (x < n) && (int(s[x]) - int('0') >= 5)) {
    s[x] = '*';
    t--;
    x--;
    while ((t > 0) && (s[x] != '.')) {
      if (int(s[x]) - int('0') + 1 >= 5) {
        s[x] = '*';
        x--;
        t--;
        id--;
      } else
        break;
    }
    if (0 == 1)
      cout << " id = " << id << " x = " << x << " after = " << after
           << " t = " << t << '\n';
    ;
    arr[id]++;
    for (i = id; i >= 1; i--) {
      arr[i - 1] += arr[i] / 10;
      arr[i] = arr[i] % 10;
    }
    ans = "";
    if (arr[0] > 0) ans += char(int('0') + arr[0]);
    x = 1;
    while (x <= after) {
      ans += char(int('0') + arr[x]);
      x++;
    }
    if (s[x] != '*') {
      ans += ".";
      while (s[x] != '*') {
        ans += char(int('0') + arr[x]);
        x++;
      }
    }
    cout << ans;
  } else
    cout << s;
  return 0;
}
