#include <bits/stdc++.h>
using namespace std;
const int INF = 1e9 + 7;
const long long LL_INF = 1ll * INF * INF;
const int MAX_N = 100000 + 7;
template <typename T>
inline void addmod(T& a, const long long& b, const int& MOD = INF) {
  a = (a + b) % MOD;
  if (a < 0) a += MOD;
}
const long double oo = (long double)1e18;
struct LineHull {
  struct Line {
    long double a, b;
    Line(long double a, long double b) : a(a), b(b) {}
  };
  long double intersect(Line ln1, Line ln2) {
    return (long double)(ln2.b - ln1.b) / (ln1.a - ln2.a);
  }
  int bad(Line ln1, Line ln2, Line ln3) {
    return (long double)(ln1.a - ln2.a) * (ln2.b - ln3.b) >=
           (long double)(ln2.a - ln3.a) * (ln1.b - ln2.b);
  }
  vector<Line> hull;
  vector<long double> pos;
  LineHull() {
    pos.push_back(-oo);
    pos.push_back(+oo);
  }
  void add(long double a, long double b) {
    Line ln(a, b);
    pos.pop_back();
    while (hull.size() >= 2 &&
           bad(hull[hull.size() - 2], hull[hull.size() - 1], ln)) {
      hull.pop_back();
      pos.pop_back();
    }
    hull.push_back(ln);
    if (hull.size() >= 2)
      pos.push_back(intersect(hull[hull.size() - 2], hull[hull.size() - 1]));
    pos.push_back(+oo);
  }
  pair<long double, int> query(long double x) {
    if (!hull.size()) return {+oo, -1};
    int k = lower_bound(pos.begin(), pos.end(), x) - pos.begin() - 1;
    return {hull[k].a * x + hull[k].b, k};
  }
} lh;
int n;
long long max_t;
int a[MAX_N], b[MAX_N];
double p[MAX_N];
vector<pair<double, int>> line;
double read_p() {
  string s;
  cin >> s;
  double res = s[0] - '0';
  double k = 10;
  for (int i = 2; i < (int)(s).size(); ++i) {
    res = res + (s[i] - '0') / k;
    k *= 10;
  }
  return res;
}
long double calc(double f, double a, double best, long long len,
                 long long base = 0) {
  return ((a + best * (len + base)) * (1 - pow(1 - f, len))) +
         best * (len * pow(1 - f, len) + pow(1 - f, len) / f - 1 / f);
}
void solve() {
  cin >> n >> max_t;
  double best = 0;
  for (int i = 0; i < n; ++i) {
    cin >> a[i] >> b[i];
    p[i] = read_p();
    best = max(best, b[i] * p[i]);
    line.push_back({p[i], a[i]});
  }
  sort(line.begin(), line.end());
  for (auto x : line) {
    lh.add(x.first, x.first * x.second);
  }
  long double res = 0;
  for (long long i = max_t; i > 0;) {
    auto tmp = lh.query(best * (max_t - i) - res);
    int k = tmp.second;
    double f = lh.hull[k].a;
    double a = lh.hull[k].b / f;
    long long lo = 1, hi = i, found = i;
    while (lo <= hi) {
      long long mid = (lo + hi) >> 1;
      long long len = i - mid + 1;
      long double prev =
          pow(1 - f, len - 1) * res + calc(f, a, best, len - 1, max_t - i);
      auto ans = lh.query(best * (max_t - mid) - prev);
      if (ans.second == k) {
        found = mid;
        hi = mid - 1;
      } else {
        lo = mid + 1;
      }
    }
    long long len = i - found + 1;
    res = pow(1 - f, len) * res + calc(f, a, best, len, max_t - i);
    i = found - 1;
  }
  cout << fixed << setprecision(6) << res << '\n';
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  const bool multiple_test = false;
  int test = 1;
  if (multiple_test) cin >> test;
  for (int i = 0; i < test; ++i) {
    solve();
  }
}
