Problem: A country Gizevom is being under a sneak and fierce attack by their foe. They have to deploy one or more troops to every base immediately in order to defend their country. Otherwise their foe would take all the bases and declare "All your base are belong to us."

You are asked to write a program that calculates the minimum time required for deployment, given the present positions and marching speeds of troops and the positions of the bases.



Input

The input consists of multiple datasets. Each dataset has the following format:

N M
x1 y1 v1
x2 y2 v2
...
xN yN vN
x'1 y'1
x'2 y'2
...
x'M y'M


N is the number of troops (1 ≤ N ≤ 100); M is the number of bases (1 ≤ M ≤ 100); (xi, yi ) denotes the present position of i-th troop; vi is the speed of the i-th troop (1 ≤ vi ≤ 100); (x'j, y'j) is the position of the j-th base.

All the coordinates are integers between 0 and 10000 inclusive.

The last dataset is followed by a line containing two zeros. This line is not a part of any dataset and should not be processed.

Output

For each dataset, print the minimum required time in a line.

Example

Input

2 2
10 20 1
0 10 1
0 10
10 0
0 0


Output

14.14213562

Solution (in CPP):

Solution:
/*
16:50 - 17:23
 */

#include<iostream>
#include<cstdio>
#include<cmath>
#include<vector>
#include<algorithm>
#include<cassert>
#include<climits>
#include<iomanip>
#include<string>
#include<cstring>
#include<cstdlib>

#define REP(i,s,n) for(int i=s;i<n;i++)
#define rep(i,n) REP(i,0,n)
#define IINF (INT_MAX)
#define EPS (1e-9)
#define equals(a,b) (fabs((a)-(b)) < EPS)
#define MAX 500
#define pow2(a) ((a)*(a))

using namespace std;


// Library - maxflow - begin 17:01
struct edge{
  int to,cap,rev;
  edge(int to=IINF,int cap=IINF,int rev=IINF):to(to),cap(cap),rev(rev){}
};

vector<vector<edge>> G;
bool used[MAX];

void add_edge(int from,int to,int cap){
  G[from].push_back(edge(to,cap,G[to].size()));
  G[to].push_back(edge(from,0,G[from].size()-1));
}

int dfs(int v,int t,int f){
  if(v==t)return f;
  used[v] = true;
  for(int i=0;i<G[v].size();i++){
    edge &e = G[v][i];
    if(!used[e.to] && e.cap > 0){
      int d = dfs(e.to,t,min(f,e.cap));
      if(d>0){
	e.cap -= d;
	G[e.to][e.rev].cap += d;
	return d;
      }
    }
  }
  return 0;
}

int max_flow(int s,int t){
  int flow = 0;
  for(;;){
    memset(used,0,sizeof(used));
    int f = dfs(s,t,IINF);
    if(f == 0)return flow;
    flow += f;
  }
}

// Library - maxflow - end 17:07

struct Point{
  double x,y,v;
  Point(double x=IINF,double y=IINF,double v=IINF):x(x),y(y),v(v){}
};

struct Data{
  double cost;
  int from,to;
  Data(double cost=IINF,int from=IINF,int to=IINF):cost(cost),from(from),to(to){}
  bool operator < (const Data& a)const{ return cost < a.cost; }
};

int N,M,source,sink;
Point troops[MAX];
Point base[MAX];
bool check[MAX];
vector<Data> info;


inline double getDist(Point a,Point b){ return sqrt(pow2(a.x-b.x)+pow2(b.y-a.y)); }

int main(){
  while(cin >> N >> M, N|M){
    info.clear();
    rep(i,N)cin >> troops[i].x >> troops[i].y >> troops[i].v;
    rep(i,M){
      cin >> base[i].x >> base[i].y; check[i] = false;
      rep(j,N)info.push_back(Data(getDist(base[i],troops[j])/troops[j].v,j,N+i));
    }
    sort(info.begin(),info.end());
    source = N+M; sink = source+1;
    G.resize(sink+1);
    rep(i,sink+1)G[i].clear();
    rep(i,N)add_edge(source,i,1);
    rep(i,M)add_edge(N+i,sink,1);
    int finish = 0;
    /*
    int sp = 0;
    rep(i,info.size()){
      add_edge(info[i].from,info[i].to,1);
      if(!check[info[i].to-N]){ finish++; check[info[i].to-N] = true; }
      sp = i + 1;
      if(finish == M)break;
    }
    */
    vector<vector<edge>> tmp = G;
    double ans = IINF;
    double L = 0, R = (1<<27),H;
    rep(_,100){
      H = (L+R)*0.5;
      G = tmp;
      rep(i,info.size()){
	if(equals(info[i].cost,H) || info[i].cost < H)add_edge(info[i].from,info[i].to,1);
	else break;
      }
      if(max_flow(source,sink) == M){
	ans = min(ans,H);
	R = H;
      } else L = H;
    }

    cout << setiosflags(ios::fixed) << setprecision(8) << ans << endl;

  }
  return 0;
}