#include<stdio.h>
#include<string.h>
#define N 110000
struct node {
int father,count;
}pre[N];
int find(int x) {
if(x==pre[x].father) {
pre[x].count=0;
return x;
}
int h=pre[x].father;
pre[x].father=find(pre[x].father);
pre[x].count+=pre[h].count;
return pre[x].father;
}
int main() {
int n,m,a,b,i;
while(scanf("%d%d",&n,&m),n||m) {
for(i=1;i<=n;i++) {
pre[i].father=i;
pre[i].count=1;
}
for(i=1;i<n;i++) {
scanf("%d%d",&a,&b);
pre[b].father=a;
}
while(m--) {
scanf("%d%d",&a,&b);
find(a);find(b);
if(pre[a].count<=pre[b].count)
printf("lxh
");
else
printf("pfz
");
}
}
return 0;
}