Given the following C code and unoptimized assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include <stdio.h>
#include <stdlib.h>
#include <math.h>

#define UNION_FIND_MAX 100

int uf_table[UNION_FIND_MAX];

void uf_init(void) {
	int i;
	for(i=0;i<UNION_FIND_MAX;i++)uf_table[i]=0;
}

void uf_merge(int a,int b) {
	int next;
	while(uf_table[a]>0) {
		next=uf_table[a]-1;
		if(uf_table[next]>0)uf_table[a]=uf_table[next];
		a=next;
	}
	while(uf_table[b]>0) {
		next=uf_table[b]-1;
		if(uf_table[next]>0)uf_table[b]=uf_table[next];
		b=next;
	}
	if(a!=b)uf_table[a]=b+1;
}

int uf_issame(int a,int b) {
	int next;
	while(uf_table[a]>0) {
		next=uf_table[a]-1;
		if(uf_table[next]>0)uf_table[a]=uf_table[next];
		a=next;
	}
	while(uf_table[b]>0) {
		next=uf_table[b]-1;
		if(uf_table[next]>0)uf_table[b]=uf_table[next];
		b=next;
	}
	return a==b;
}

typedef struct {
	int from,to;
	double cost;
} edge_t;

typedef struct {
	double x,y,z,r;
} node_t;

int qsort_comp(const void* x,const void* y) {
	const edge_t* a=(const edge_t*)x;
	const edge_t* b=(const edge_t*)y;
	if((a->cost)>(b->cost))return 1;
	if((a->cost)<(b->cost))return -1;
	return 0;
}

int n;
node_t node[100];
edge_t edge[10000];

int main(void) {
	int i,j,p,c;
	double result;
	while(scanf("%d",&n)==1 && n>0) {
		for(i=0;i<n;i++)scanf("%lf%lf%lf%lf",
			&node[i].x,&node[i].y,&node[i].z,&node[i].r);
		p=0;
		for(i=0;i<n;i++) {
			for(j=i+1;j<n;j++) {
				edge[p].from=i;
				edge[p].to=j;
				edge[p].cost=sqrt(
					(node[i].x-node[j].x)*(node[i].x-node[j].x)+
					(node[i].y-node[j].y)*(node[i].y-node[j].y)+
					(node[i].z-node[j].z)*(node[i].z-node[j].z)
				)-node[i].r-node[j].r;
				if(edge[p].cost<=0)edge[p].cost=0;
				p++;
			}
		}
		qsort(edge,p,sizeof(edge_t),qsort_comp);
		c=1;
		result=0;
		uf_init();
		for(i=0;i<p && c<n;i++) {
			if(!uf_issame(edge[i].from,edge[i].to)) {
				c++;
				result+=edge[i].cost;
				uf_merge(edge[i].from,edge[i].to);
			}
		}
		printf("%.3f\n",result);
	}
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	uf_table
	.bss
	.align 32
	.type	uf_table, @object
	.size	uf_table, 400
uf_table:
	.zero	400
	.text
	.globl	uf_init
	.type	uf_init, @function
uf_init:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	$0, -4(%rbp)
	jmp	.L2
.L3:
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	$0, (%rdx,%rax)
	addl	$1, -4(%rbp)
.L2:
	cmpl	$99, -4(%rbp)
	jle	.L3
	nop
	nop
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	uf_init, .-uf_init
	.globl	uf_merge
	.type	uf_merge, @function
uf_merge:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	jmp	.L5
.L7:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L6
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L6:
	movl	-4(%rbp), %eax
	movl	%eax, -20(%rbp)
.L5:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L7
	jmp	.L8
.L10:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L9
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L9:
	movl	-4(%rbp), %eax
	movl	%eax, -24(%rbp)
.L8:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L10
	movl	-20(%rbp), %eax
	cmpl	-24(%rbp), %eax
	je	.L12
	movl	-24(%rbp), %eax
	leal	1(%rax), %ecx
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	%ecx, (%rdx,%rax)
.L12:
	nop
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	uf_merge, .-uf_merge
	.globl	uf_issame
	.type	uf_issame, @function
uf_issame:
.LFB8:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	jmp	.L14
.L16:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L15
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L15:
	movl	-4(%rbp), %eax
	movl	%eax, -20(%rbp)
.L14:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L16
	jmp	.L17
.L19:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L18
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L18:
	movl	-4(%rbp), %eax
	movl	%eax, -24(%rbp)
.L17:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L19
	movl	-20(%rbp), %eax
	cmpl	-24(%rbp), %eax
	sete	%al
	movzbl	%al, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	uf_issame, .-uf_issame
	.globl	qsort_comp
	.type	qsort_comp, @function
qsort_comp:
.LFB9:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movq	%rsi, -32(%rbp)
	movq	-24(%rbp), %rax
	movq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -8(%rbp)
	movq	-16(%rbp), %rax
	movsd	8(%rax), %xmm0
	movq	-8(%rbp), %rax
	movsd	8(%rax), %xmm1
	comisd	%xmm1, %xmm0
	jbe	.L29
	movl	$1, %eax
	jmp	.L24
.L29:
	movq	-16(%rbp), %rax
	movsd	8(%rax), %xmm1
	movq	-8(%rbp), %rax
	movsd	8(%rax), %xmm0
	comisd	%xmm1, %xmm0
	jbe	.L30
	movl	$-1, %eax
	jmp	.L24
.L30:
	movl	$0, %eax
.L24:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	qsort_comp, .-qsort_comp
	.globl	n
	.bss
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	node
	.align 32
	.type	node, @object
	.size	node, 3200
node:
	.zero	3200
	.globl	edge
	.align 32
	.type	edge, @object
	.size	edge, 160000
edge:
	.zero	160000
	.section	.rodata
.LC0:
	.string	"%lf%lf%lf%lf"
.LC2:
	.string	"%.3f\n"
.LC3:
	.string	"%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB10:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$32, %rsp
	jmp	.L32
.L46:
	movl	$0, -24(%rbp)
	jmp	.L33
.L34:
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	leaq	16(%rax), %rdx
	leaq	node(%rip), %rax
	addq	%rdx, %rax
	leaq	8(%rax), %rsi
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	leaq	16(%rax), %rdx
	leaq	node(%rip), %rax
	leaq	(%rdx,%rax), %rcx
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	addq	%rdx, %rax
	leaq	8(%rax), %rdx
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdi
	leaq	node(%rip), %rax
	addq	%rdi, %rax
	movq	%rsi, %r8
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -24(%rbp)
.L33:
	movl	n(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L34
	movl	$0, -16(%rbp)
	movl	$0, -24(%rbp)
	jmp	.L35
.L40:
	movl	-24(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -20(%rbp)
	jmp	.L36
.L39:
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	edge(%rip), %rdx
	movl	-24(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	4+edge(%rip), %rdx
	movl	-20(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm2
	movapd	%xmm0, %xmm1
	subsd	%xmm2, %xmm1
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm2
	subsd	%xmm2, %xmm0
	mulsd	%xmm0, %xmm1
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	movapd	%xmm0, %xmm2
	subsd	%xmm3, %xmm2
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	subsd	%xmm3, %xmm0
	mulsd	%xmm2, %xmm0
	addsd	%xmm0, %xmm1
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	movapd	%xmm0, %xmm2
	subsd	%xmm3, %xmm2
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	subsd	%xmm3, %xmm0
	mulsd	%xmm2, %xmm0
	addsd	%xmm0, %xmm1
	movq	%xmm1, %rax
	movq	%rax, %xmm0
	call	sqrt@PLT
	movq	%xmm0, %rax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	movq	%rdx, %rcx
	salq	$5, %rcx
	leaq	24+node(%rip), %rdx
	movsd	(%rcx,%rdx), %xmm1
	movq	%rax, %xmm0
	subsd	%xmm1, %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	24+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm1
	subsd	%xmm1, %xmm0
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	movsd	%xmm0, (%rdx,%rax)
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	movsd	(%rdx,%rax), %xmm1
	pxor	%xmm0, %xmm0
	comisd	%xmm1, %xmm0
	jb	.L37
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	pxor	%xmm0, %xmm0
	movsd	%xmm0, (%rdx,%rax)
.L37:
	addl	$1, -16(%rbp)
	addl	$1, -20(%rbp)
.L36:
	movl	n(%rip), %eax
	cmpl	%eax, -20(%rbp)
	jl	.L39
	addl	$1, -24(%rbp)
.L35:
	movl	n(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L40
	movl	-16(%rbp), %eax
	cltq
	leaq	qsort_comp(%rip), %rdx
	movq	%rdx, %rcx
	movl	$16, %edx
	movq	%rax, %rsi
	leaq	edge(%rip), %rax
	movq	%rax, %rdi
	call	qsort@PLT
	movl	$1, -12(%rbp)
	pxor	%xmm0, %xmm0
	movsd	%xmm0, -8(%rbp)
	call	uf_init
	movl	$0, -24(%rbp)
	jmp	.L41
.L44:
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+edge(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	edge(%rip), %rax
	movl	(%rcx,%rax), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	uf_issame
	testl	%eax, %eax
	jne	.L42
	addl	$1, -12(%rbp)
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movsd	-8(%rbp), %xmm1
	addsd	%xmm1, %xmm0
	movsd	%xmm0, -8(%rbp)
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+edge(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	edge(%rip), %rax
	movl	(%rcx,%rax), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	uf_merge
.L42:
	addl	$1, -24(%rbp)
.L41:
	movl	-24(%rbp), %eax
	cmpl	-16(%rbp), %eax
	jge	.L43
	movl	n(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L44
.L43:
	movq	-8(%rbp), %rax
	movq	%rax, %xmm0
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$1, %eax
	call	printf@PLT
.L32:
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	cmpl	$1, %eax
	jne	.L45
	movl	n(%rip), %eax
	testl	%eax, %eax
	jg	.L46
.L45:
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
user
	.file	"temp.c"
	.text
	.p2align 4
	.globl	qsort_comp
	.type	qsort_comp, @function
qsort_comp:
.LFB42:
	.cfi_startproc
	endbr64
	movsd	8(%rdi), %xmm0
	movsd	8(%rsi), %xmm1
	movl	$1, %eax
	comisd	%xmm1, %xmm0
	ja	.L1
	xorl	%eax, %eax
	comisd	%xmm0, %xmm1
	seta	%al
	negl	%eax
.L1:
	ret
	.cfi_endproc
.LFE42:
	.size	qsort_comp, .-qsort_comp
	.p2align 4
	.globl	uf_init
	.type	uf_init, @function
uf_init:
.LFB39:
	.cfi_startproc
	endbr64
	leaq	uf_table(%rip), %rdx
	movl	$50, %ecx
	xorl	%eax, %eax
	movq	%rdx, %rdi
	rep stosq
	ret
	.cfi_endproc
.LFE39:
	.size	uf_init, .-uf_init
	.p2align 4
	.globl	uf_merge
	.type	uf_merge, @function
uf_merge:
.LFB40:
	.cfi_startproc
	endbr64
	leaq	uf_table(%rip), %rax
	movslq	%edi, %rcx
	movl	(%rax,%rcx,4), %r8d
	testl	%r8d, %r8d
	jle	.L14
	subl	$1, %r8d
	movslq	%r8d, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L20
	.p2align 4,,10
	.p2align 3
.L8:
	movl	%edx, (%rax,%rcx,4)
	leal	-1(%rdx), %ecx
	movl	%r8d, %edi
	movslq	%ecx, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L7
	movl	%ecx, %r8d
	movslq	%edi, %rcx
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L20:
	movl	%r8d, %ecx
	.p2align 4,,10
	.p2align 3
.L7:
	movslq	%esi, %rdi
	movl	(%rax,%rdi,4), %r8d
	testl	%r8d, %r8d
	jle	.L16
.L22:
	subl	$1, %r8d
	movslq	%r8d, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L21
	.p2align 4,,10
	.p2align 3
.L11:
	movl	%edx, (%rax,%rdi,4)
	leal	-1(%rdx), %edi
	movl	%r8d, %esi
	movslq	%edi, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L10
	movl	%edi, %r8d
	movslq	%esi, %rdi
	jmp	.L11
	.p2align 4,,10
	.p2align 3
.L21:
	movl	%r8d, %edi
	.p2align 4,,10
	.p2align 3
.L10:
	cmpl	%edi, %ecx
	je	.L6
	movslq	%ecx, %rcx
	addl	$1, %edi
	movl	%edi, (%rax,%rcx,4)
.L6:
	ret
	.p2align 4,,10
	.p2align 3
.L14:
	movl	%edi, %ecx
	movslq	%esi, %rdi
	movl	(%rax,%rdi,4), %r8d
	testl	%r8d, %r8d
	jg	.L22
	.p2align 4,,10
	.p2align 3
.L16:
	movl	%esi, %edi
	jmp	.L10
	.cfi_endproc
.LFE40:
	.size	uf_merge, .-uf_merge
	.p2align 4
	.globl	uf_issame
	.type	uf_issame, @function
uf_issame:
.LFB41:
	.cfi_startproc
	endbr64
	leaq	uf_table(%rip), %rax
	movslq	%edi, %r8
	movl	(%rax,%r8,4), %ecx
	testl	%ecx, %ecx
	jle	.L30
	subl	$1, %ecx
	movslq	%ecx, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L36
	.p2align 4,,10
	.p2align 3
.L25:
	movl	%edx, (%rax,%r8,4)
	leal	-1(%rdx), %r8d
	movl	%ecx, %edi
	movslq	%r8d, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L24
	movl	%r8d, %ecx
	movslq	%edi, %r8
	jmp	.L25
	.p2align 4,,10
	.p2align 3
.L36:
	movl	%ecx, %r8d
	.p2align 4,,10
	.p2align 3
.L24:
	movslq	%esi, %rcx
	movl	(%rax,%rcx,4), %edi
	testl	%edi, %edi
	jle	.L32
.L38:
	subl	$1, %edi
	movslq	%edi, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L37
	.p2align 4,,10
	.p2align 3
.L28:
	movl	%edx, (%rax,%rcx,4)
	leal	-1(%rdx), %ecx
	movl	%edi, %esi
	movslq	%ecx, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L27
	movl	%ecx, %edi
	movslq	%esi, %rcx
	jmp	.L28
	.p2align 4,,10
	.p2align 3
.L37:
	movl	%edi, %ecx
.L27:
	xorl	%eax, %eax
	cmpl	%ecx, %r8d
	sete	%al
	ret
	.p2align 4,,10
	.p2align 3
.L30:
	movslq	%esi, %rcx
	movl	%edi, %r8d
	movl	(%rax,%rcx,4), %edi
	testl	%edi, %edi
	jg	.L38
.L32:
	movl	%esi, %ecx
	xorl	%eax, %eax
	cmpl	%ecx, %r8d
	sete	%al
	ret
	.cfi_endproc
.LFE41:
	.size	uf_issame, .-uf_issame
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC1:
	.string	"%lf%lf%lf%lf"
.LC2:
	.string	"%.3f\n"
.LC3:
	.string	"%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB43:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	leaq	.LC1(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	uf_table(%rip), %rbx
	subq	$88, %rsp
	.cfi_def_cfa_offset 144
	.p2align 4,,10
	.p2align 3
.L40:
	leaq	n(%rip), %rsi
	leaq	.LC3(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	%eax, %r13d
	cmpl	$1, %eax
	jne	.L81
	movl	n(%rip), %eax
	testl	%eax, %eax
	jle	.L81
	leaq	node(%rip), %rbp
	xorl	%r14d, %r14d
	.p2align 4,,10
	.p2align 3
.L41:
	leaq	8(%rbp), %rdx
	leaq	16(%rbp), %rcx
	movq	%rbp, %rsi
	movq	%r12, %rdi
	leaq	24(%rbp), %r8
	xorl	%eax, %eax
	addl	$1, %r14d
	addq	$32, %rbp
	call	__isoc99_scanf@PLT
	movl	n(%rip), %edx
	cmpl	%r14d, %edx
	jg	.L41
	testl	%edx, %edx
	jle	.L43
	cmpl	$1, %edx
	je	.L43
	leal	-1(%rdx), %r9d
	leaq	32+node(%rip), %rax
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	movq	%r9, %rdi
	pxor	%xmm2, %xmm2
	.p2align 4,,10
	.p2align 3
.L49:
	movslq	%r8d, %r14
	leaq	edge(%rip), %r10
	movl	%ecx, %esi
	movq	%rax, %rbp
	salq	$4, %r14
	movsd	-32(%rax), %xmm5
	movsd	-24(%rax), %xmm4
	movd	%ecx, %xmm6
	movsd	-16(%rax), %xmm3
	leal	1(%rcx), %r15d
	addq	%r10, %r14
	.p2align 4,,10
	.p2align 3
.L48:
	movd	%r15d, %xmm7
	movdqa	%xmm6, %xmm0
	movapd	%xmm3, %xmm1
	punpckldq	%xmm7, %xmm0
	movapd	%xmm4, %xmm7
	subsd	8(%rbp), %xmm7
	movq	%xmm0, (%r14)
	movapd	%xmm5, %xmm0
	subsd	0(%rbp), %xmm0
	subsd	16(%rbp), %xmm1
	mulsd	%xmm7, %xmm7
	mulsd	%xmm0, %xmm0
	mulsd	%xmm1, %xmm1
	addsd	%xmm7, %xmm0
	addsd	%xmm1, %xmm0
	ucomisd	%xmm0, %xmm2
	ja	.L89
	sqrtsd	%xmm0, %xmm0
.L46:
	subsd	-8(%rax), %xmm0
	addl	$1, %r15d
	addq	$16, %r14
	addq	$32, %rbp
	subsd	-8(%rbp), %xmm0
	movapd	%xmm0, %xmm1
	cmpnlesd	%xmm2, %xmm1
	andpd	%xmm1, %xmm0
	movsd	%xmm0, -8(%r14)
	cmpl	%r15d, %edx
	jg	.L48
	addl	%edi, %r8d
	addq	$1, %rcx
	addq	$32, %rax
	subl	%esi, %r8d
	cmpq	%r9, %rcx
	jne	.L49
	movslq	%r8d, %rsi
	movl	$16, %edx
	movl	%r8d, 12(%rsp)
	leaq	qsort_comp(%rip), %rcx
	leaq	edge(%rip), %rdi
	call	qsort@PLT
	movl	12(%rsp), %r8d
	xorl	%eax, %eax
	movq	%rbx, %rdi
	movl	$50, %ecx
	leaq	edge(%rip), %r9
	pxor	%xmm2, %xmm2
	movl	n(%rip), %r10d
	rep stosq
	leal	-1(%r8), %r11d
	leaq	16(%r9), %rax
	movapd	%xmm2, %xmm0
	salq	$4, %r11
	addq	%rax, %r11
	.p2align 4,,10
	.p2align 3
.L68:
	cmpl	%r13d, %r10d
	jle	.L64
	movslq	(%r9), %r8
	movl	4(%r9), %edi
	movl	(%rbx,%r8,4), %ecx
	movq	%r8, %rsi
	testl	%ecx, %ecx
	jle	.L70
	subl	$1, %ecx
	movslq	%r8d, %rdx
	movslq	%ecx, %rax
	movl	%ecx, %ebp
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L51
	.p2align 4,,10
	.p2align 3
.L52:
	leal	-1(%rax), %ebp
	movl	%eax, (%rbx,%rdx,4)
	movslq	%ecx, %rdx
	movslq	%ebp, %rax
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L51
	movl	%ebp, %ecx
	jmp	.L52
.L70:
	movl	%r8d, %ebp
	.p2align 4,,10
	.p2align 3
.L51:
	movslq	%edi, %r15
	movl	(%rbx,%r15,4), %r14d
	testl	%r14d, %r14d
	jle	.L73
	subl	$1, %r14d
	movslq	%edi, %rdx
	movslq	%r14d, %rax
	movl	%r14d, %ecx
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L54
	.p2align 4,,10
	.p2align 3
.L55:
	leal	-1(%rax), %ecx
	movl	%eax, (%rbx,%rdx,4)
	movslq	%r14d, %rdx
	movslq	%ecx, %rax
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L54
	movl	%ecx, %r14d
	jmp	.L55
.L73:
	movl	%edi, %ecx
	.p2align 4,,10
	.p2align 3
.L54:
	cmpl	%ecx, %ebp
	jne	.L97
.L57:
	addq	$16, %r9
	cmpq	%r11, %r9
	jne	.L68
.L64:
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	movl	$1, %eax
	call	__printf_chk@PLT
	jmp	.L40
	.p2align 4,,10
	.p2align 3
.L97:
	movl	(%rbx,%r8,4), %edx
	addsd	8(%r9), %xmm0
	addl	$1, %r13d
	testl	%edx, %edx
	jle	.L58
	subl	$1, %edx
	movslq	%edx, %rax
	movl	%edx, %esi
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L58
	.p2align 4,,10
	.p2align 3
.L59:
	leal	-1(%rax), %esi
	movl	%eax, (%rbx,%r8,4)
	movslq	%edx, %r8
	movslq	%esi, %rax
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L58
	movl	%esi, %edx
	jmp	.L59
	.p2align 4,,10
	.p2align 3
.L58:
	movl	(%rbx,%r15,4), %edx
	testl	%edx, %edx
	jle	.L61
	subl	$1, %edx
	movslq	%edx, %rax
	movl	%edx, %edi
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L61
	.p2align 4,,10
	.p2align 3
.L62:
	leal	-1(%rax), %edi
	movl	%eax, (%rbx,%r15,4)
	movslq	%edx, %r15
	movslq	%edi, %rax
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L61
	movl	%edi, %edx
	jmp	.L62
	.p2align 4,,10
	.p2align 3
.L61:
	cmpl	%edi, %esi
	je	.L57
	movslq	%esi, %rsi
	addl	$1, %edi
	movl	%edi, (%rbx,%rsi,4)
	jmp	.L57
.L81:
	addq	$88, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
.L43:
	.cfi_restore_state
	leaq	qsort_comp(%rip), %rcx
	leaq	edge(%rip), %rdi
	movl	$16, %edx
	xorl	%esi, %esi
	call	qsort@PLT
	movl	$50, %ecx
	xorl	%eax, %eax
	movq	%rbx, %rdi
	rep stosq
	pxor	%xmm0, %xmm0
	jmp	.L64
.L89:
	movl	%edi, 76(%rsp)
	movq	%r9, 40(%rsp)
	movl	%r8d, 36(%rsp)
	movl	%esi, 32(%rsp)
	movq	%rcx, 24(%rsp)
	movq	%rax, 16(%rsp)
	movl	%edx, 12(%rsp)
	movsd	%xmm3, 64(%rsp)
	movsd	%xmm4, 56(%rsp)
	movsd	%xmm5, 48(%rsp)
	movd	%xmm6, 72(%rsp)
	call	sqrt@PLT
	movl	76(%rsp), %edi
	movq	40(%rsp), %r9
	pxor	%xmm2, %xmm2
	movsd	64(%rsp), %xmm3
	movsd	56(%rsp), %xmm4
	movsd	48(%rsp), %xmm5
	movd	72(%rsp), %xmm6
	movl	36(%rsp), %r8d
	movl	32(%rsp), %esi
	movq	24(%rsp), %rcx
	movq	16(%rsp), %rax
	movl	12(%rsp), %edx
	jmp	.L46
	.cfi_endproc
.LFE43:
	.size	main, .-main
	.globl	edge
	.bss
	.align 32
	.type	edge, @object
	.size	edge, 160000
edge:
	.zero	160000
	.globl	node
	.align 32
	.type	node, @object
	.size	node, 3200
node:
	.zero	3200
	.globl	n
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	uf_table
	.align 32
	.type	uf_table, @object
	.size	uf_table, 400
uf_table:
	.zero	400
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:

rule
	.file	"temp.c"
	.text
	.p2align 4
	.globl	qsort_comp
	.type	qsort_comp, @function
qsort_comp:
.LFB42:
	.cfi_startproc
	endbr64
	movsd	8(%rdi), %xmm0
	movsd	8(%rsi), %xmm1
	movl	$1, %eax
	comisd	%xmm1, %xmm0
	ja	.L1
	xorl	%eax, %eax
	comisd	%xmm0, %xmm1
	seta	%al
	negl	%eax
.L1:
	ret
	.cfi_endproc
.LFE42:
	.size	qsort_comp, .-qsort_comp
	.p2align 4
	.globl	uf_init
	.type	uf_init, @function
uf_init:
.LFB39:
	.cfi_startproc
	endbr64
	leaq	uf_table(%rip), %rdx
	movl	$50, %ecx
	xorl	%eax, %eax
	movq	%rdx, %rdi
	rep stosq
	ret
	.cfi_endproc
.LFE39:
	.size	uf_init, .-uf_init
	.p2align 4
	.globl	uf_merge
	.type	uf_merge, @function
uf_merge:
.LFB40:
	.cfi_startproc
	endbr64
	leaq	uf_table(%rip), %rax
	movslq	%edi, %rcx
	movl	(%rax,%rcx,4), %r8d
	testl	%r8d, %r8d
	jle	.L14
	subl	$1, %r8d
	movslq	%r8d, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L20
	.p2align 4,,10
	.p2align 3
.L8:
	movl	%edx, (%rax,%rcx,4)
	leal	-1(%rdx), %ecx
	movl	%r8d, %edi
	movslq	%ecx, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L7
	movl	%ecx, %r8d
	movslq	%edi, %rcx
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L20:
	movl	%r8d, %ecx
	.p2align 4,,10
	.p2align 3
.L7:
	movslq	%esi, %rdi
	movl	(%rax,%rdi,4), %r8d
	testl	%r8d, %r8d
	jle	.L16
.L22:
	subl	$1, %r8d
	movslq	%r8d, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L21
	.p2align 4,,10
	.p2align 3
.L11:
	movl	%edx, (%rax,%rdi,4)
	leal	-1(%rdx), %edi
	movl	%r8d, %esi
	movslq	%edi, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L10
	movl	%edi, %r8d
	movslq	%esi, %rdi
	jmp	.L11
	.p2align 4,,10
	.p2align 3
.L21:
	movl	%r8d, %edi
	.p2align 4,,10
	.p2align 3
.L10:
	cmpl	%edi, %ecx
	je	.L6
	movslq	%ecx, %rcx
	addl	$1, %edi
	movl	%edi, (%rax,%rcx,4)
.L6:
	ret
	.p2align 4,,10
	.p2align 3
.L14:
	movl	%edi, %ecx
	movslq	%esi, %rdi
	movl	(%rax,%rdi,4), %r8d
	testl	%r8d, %r8d
	jg	.L22
	.p2align 4,,10
	.p2align 3
.L16:
	movl	%esi, %edi
	jmp	.L10
	.cfi_endproc
.LFE40:
	.size	uf_merge, .-uf_merge
	.p2align 4
	.globl	uf_issame
	.type	uf_issame, @function
uf_issame:
.LFB41:
	.cfi_startproc
	endbr64
	leaq	uf_table(%rip), %rax
	movslq	%edi, %r8
	movl	(%rax,%r8,4), %ecx
	testl	%ecx, %ecx
	jle	.L30
	subl	$1, %ecx
	movslq	%ecx, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L36
	.p2align 4,,10
	.p2align 3
.L25:
	movl	%edx, (%rax,%r8,4)
	leal	-1(%rdx), %r8d
	movl	%ecx, %edi
	movslq	%r8d, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L24
	movl	%r8d, %ecx
	movslq	%edi, %r8
	jmp	.L25
	.p2align 4,,10
	.p2align 3
.L36:
	movl	%ecx, %r8d
	.p2align 4,,10
	.p2align 3
.L24:
	movslq	%esi, %rcx
	movl	(%rax,%rcx,4), %edi
	testl	%edi, %edi
	jle	.L32
.L38:
	subl	$1, %edi
	movslq	%edi, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L37
	.p2align 4,,10
	.p2align 3
.L28:
	movl	%edx, (%rax,%rcx,4)
	leal	-1(%rdx), %ecx
	movl	%edi, %esi
	movslq	%ecx, %rdx
	movl	(%rax,%rdx,4), %edx
	testl	%edx, %edx
	jle	.L27
	movl	%ecx, %edi
	movslq	%esi, %rcx
	jmp	.L28
	.p2align 4,,10
	.p2align 3
.L37:
	movl	%edi, %ecx
.L27:
	xorl	%eax, %eax
	cmpl	%ecx, %r8d
	sete	%al
	ret
	.p2align 4,,10
	.p2align 3
.L30:
	movslq	%esi, %rcx
	movl	%edi, %r8d
	movl	(%rax,%rcx,4), %edi
	testl	%edi, %edi
	jg	.L38
.L32:
	movl	%esi, %ecx
	xorl	%eax, %eax
	cmpl	%ecx, %r8d
	sete	%al
	ret
	.cfi_endproc
.LFE41:
	.size	uf_issame, .-uf_issame
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC1:
	.string	"%lf%lf%lf%lf"
.LC2:
	.string	"%.3f\n"
.LC3:
	.string	"%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB43:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	leaq	.LC1(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	uf_table(%rip), %rbx
	subq	$88, %rsp
	.cfi_def_cfa_offset 144
	.p2align 4,,10
	.p2align 3
.L40:
	leaq	n(%rip), %rsi
	leaq	.LC3(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	%eax, %r13d
	cmpl	$1, %eax
	jne	.L81
	movl	n(%rip), %eax
	testl	%eax, %eax
	jle	.L81
	leaq	node(%rip), %rbp
	xorl	%r14d, %r14d
	.p2align 4,,10
	.p2align 3
.L41:
	leaq	8(%rbp), %rdx
	leaq	16(%rbp), %rcx
	movq	%rbp, %rsi
	movq	%r12, %rdi
	leaq	24(%rbp), %r8
	xorl	%eax, %eax
	addl	$1, %r14d
	addq	$32, %rbp
	call	__isoc99_scanf@PLT
	movl	n(%rip), %edx
	cmpl	%r14d, %edx
	jg	.L41
	testl	%edx, %edx
	jle	.L43
	cmpl	$1, %edx
	je	.L43
	leal	-1(%rdx), %r9d
	leaq	32+node(%rip), %rax
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	movq	%r9, %rdi
	pxor	%xmm2, %xmm2
	.p2align 4,,10
	.p2align 3
.L49:
	movslq	%r8d, %r14
	leaq	edge(%rip), %r10
	movl	%ecx, %esi
	movq	%rax, %rbp
	salq	$4, %r14
	movsd	-32(%rax), %xmm5
	movsd	-24(%rax), %xmm4
	movd	%ecx, %xmm6
	movsd	-16(%rax), %xmm3
	leal	1(%rcx), %r15d
	addq	%r10, %r14
	.p2align 4,,10
	.p2align 3
.L48:
	movd	%r15d, %xmm7
	movdqa	%xmm6, %xmm0
	movapd	%xmm3, %xmm1
	punpckldq	%xmm7, %xmm0
	movapd	%xmm4, %xmm7
	subsd	8(%rbp), %xmm7
	movq	%xmm0, (%r14)
	movapd	%xmm5, %xmm0
	subsd	0(%rbp), %xmm0
	subsd	16(%rbp), %xmm1
	mulsd	%xmm7, %xmm7
	mulsd	%xmm0, %xmm0
	mulsd	%xmm1, %xmm1
	addsd	%xmm7, %xmm0
	addsd	%xmm1, %xmm0
	ucomisd	%xmm0, %xmm2
	ja	.L89
	sqrtsd	%xmm0, %xmm0
.L46:
	subsd	-8(%rax), %xmm0
	addl	$1, %r15d
	addq	$16, %r14
	addq	$32, %rbp
	subsd	-8(%rbp), %xmm0
	movapd	%xmm0, %xmm1
	cmpnlesd	%xmm2, %xmm1
	andpd	%xmm1, %xmm0
	movsd	%xmm0, -8(%r14)
	cmpl	%r15d, %edx
	jg	.L48
	addl	%edi, %r8d
	addq	$1, %rcx
	addq	$32, %rax
	subl	%esi, %r8d
	cmpq	%r9, %rcx
	jne	.L49
	movslq	%r8d, %rsi
	movl	$16, %edx
	movl	%r8d, 12(%rsp)
	leaq	qsort_comp(%rip), %rcx
	leaq	edge(%rip), %rdi
	call	qsort@PLT
	movl	12(%rsp), %r8d
	xorl	%eax, %eax
	movq	%rbx, %rdi
	movl	$50, %ecx
	leaq	edge(%rip), %r9
	pxor	%xmm2, %xmm2
	movl	n(%rip), %r10d
	rep stosq
	leal	-1(%r8), %r11d
	leaq	16(%r9), %rax
	movapd	%xmm2, %xmm0
	salq	$4, %r11
	addq	%rax, %r11
	.p2align 4,,10
	.p2align 3
.L68:
	cmpl	%r13d, %r10d
	jle	.L64
	movslq	(%r9), %r8
	movl	4(%r9), %edi
	movl	(%rbx,%r8,4), %ecx
	movq	%r8, %rsi
	testl	%ecx, %ecx
	jle	.L70
	subl	$1, %ecx
	movslq	%r8d, %rdx
	movslq	%ecx, %rax
	movl	%ecx, %ebp
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L51
	.p2align 4,,10
	.p2align 3
.L52:
	leal	-1(%rax), %ebp
	movl	%eax, (%rbx,%rdx,4)
	movslq	%ecx, %rdx
	movslq	%ebp, %rax
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L51
	movl	%ebp, %ecx
	jmp	.L52
.L70:
	movl	%r8d, %ebp
	.p2align 4,,10
	.p2align 3
.L51:
	movslq	%edi, %r15
	movl	(%rbx,%r15,4), %r14d
	testl	%r14d, %r14d
	jle	.L73
	subl	$1, %r14d
	movslq	%edi, %rdx
	movslq	%r14d, %rax
	movl	%r14d, %ecx
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L54
	.p2align 4,,10
	.p2align 3
.L55:
	leal	-1(%rax), %ecx
	movl	%eax, (%rbx,%rdx,4)
	movslq	%r14d, %rdx
	movslq	%ecx, %rax
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L54
	movl	%ecx, %r14d
	jmp	.L55
.L73:
	movl	%edi, %ecx
	.p2align 4,,10
	.p2align 3
.L54:
	cmpl	%ecx, %ebp
	jne	.L97
.L57:
	addq	$16, %r9
	cmpq	%r11, %r9
	jne	.L68
.L64:
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	movl	$1, %eax
	call	__printf_chk@PLT
	jmp	.L40
	.p2align 4,,10
	.p2align 3
.L97:
	movl	(%rbx,%r8,4), %edx
	addsd	8(%r9), %xmm0
	addl	$1, %r13d
	testl	%edx, %edx
	jle	.L58
	subl	$1, %edx
	movslq	%edx, %rax
	movl	%edx, %esi
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L58
	.p2align 4,,10
	.p2align 3
.L59:
	leal	-1(%rax), %esi
	movl	%eax, (%rbx,%r8,4)
	movslq	%edx, %r8
	movslq	%esi, %rax
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L58
	movl	%esi, %edx
	jmp	.L59
	.p2align 4,,10
	.p2align 3
.L58:
	movl	(%rbx,%r15,4), %edx
	testl	%edx, %edx
	jle	.L61
	subl	$1, %edx
	movslq	%edx, %rax
	movl	%edx, %edi
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L61
	.p2align 4,,10
	.p2align 3
.L62:
	leal	-1(%rax), %edi
	movl	%eax, (%rbx,%r15,4)
	movslq	%edx, %r15
	movslq	%edi, %rax
	movl	(%rbx,%rax,4), %eax
	testl	%eax, %eax
	jle	.L61
	movl	%edi, %edx
	jmp	.L62
	.p2align 4,,10
	.p2align 3
.L61:
	cmpl	%edi, %esi
	je	.L57
	movslq	%esi, %rsi
	addl	$1, %edi
	movl	%edi, (%rbx,%rsi,4)
	jmp	.L57
.L81:
	addq	$88, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
.L43:
	.cfi_restore_state
	leaq	qsort_comp(%rip), %rcx
	leaq	edge(%rip), %rdi
	movl	$16, %edx
	xorl	%esi, %esi
	call	qsort@PLT
	movl	$50, %ecx
	xorl	%eax, %eax
	movq	%rbx, %rdi
	rep stosq
	pxor	%xmm0, %xmm0
	jmp	.L64
.L89:
	movl	%edi, 76(%rsp)
	movq	%r9, 40(%rsp)
	movl	%r8d, 36(%rsp)
	movl	%esi, 32(%rsp)
	movq	%rcx, 24(%rsp)
	movq	%rax, 16(%rsp)
	movl	%edx, 12(%rsp)
	movsd	%xmm3, 64(%rsp)
	movsd	%xmm4, 56(%rsp)
	movsd	%xmm5, 48(%rsp)
	movd	%xmm6, 72(%rsp)
	call	sqrt@PLT
	movl	76(%rsp), %edi
	movq	40(%rsp), %r9
	pxor	%xmm2, %xmm2
	movsd	64(%rsp), %xmm3
	movsd	56(%rsp), %xmm4
	movsd	48(%rsp), %xmm5
	movd	72(%rsp), %xmm6
	movl	36(%rsp), %r8d
	movl	32(%rsp), %esi
	movq	24(%rsp), %rcx
	movq	16(%rsp), %rax
	movl	12(%rsp), %edx
	jmp	.L46
	.cfi_endproc
.LFE43:
	.size	main, .-main
	.globl	edge
	.bss
	.align 32
	.type	edge, @object
	.size	edge, 160000
edge:
	.zero	160000
	.globl	node
	.align 32
	.type	node, @object
	.size	node, 3200
node:
	.zero	3200
	.globl	n
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	uf_table
	.align 32
	.type	uf_table, @object
	.size	uf_table, 400
uf_table:
	.zero	400
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:

#include <stdio.h>
#include <stdlib.h>
#include <math.h>

#define UNION_FIND_MAX 100

int uf_table[UNION_FIND_MAX];

void uf_init(void) {
	int i;
	for(i=0;i<UNION_FIND_MAX;i++)uf_table[i]=0;
}

void uf_merge(int a,int b) {
	int next;
	while(uf_table[a]>0) {
		next=uf_table[a]-1;
		if(uf_table[next]>0)uf_table[a]=uf_table[next];
		a=next;
	}
	while(uf_table[b]>0) {
		next=uf_table[b]-1;
		if(uf_table[next]>0)uf_table[b]=uf_table[next];
		b=next;
	}
	if(a!=b)uf_table[a]=b+1;
}

int uf_issame(int a,int b) {
	int next;
	while(uf_table[a]>0) {
		next=uf_table[a]-1;
		if(uf_table[next]>0)uf_table[a]=uf_table[next];
		a=next;
	}
	while(uf_table[b]>0) {
		next=uf_table[b]-1;
		if(uf_table[next]>0)uf_table[b]=uf_table[next];
		b=next;
	}
	return a==b;
}

typedef struct {
	int from,to;
	double cost;
} edge_t;

typedef struct {
	double x,y,z,r;
} node_t;

int qsort_comp(const void* x,const void* y) {
	const edge_t* a=(const edge_t*)x;
	const edge_t* b=(const edge_t*)y;
	if((a->cost)>(b->cost))return 1;
	if((a->cost)<(b->cost))return -1;
	return 0;
}

int n;
node_t node[100];
edge_t edge[10000];

int main(void) {
	int i,j,p,c;
	double result;
	while(scanf("%d",&n)==1 && n>0) {
		for(i=0;i<n;i++)scanf("%lf%lf%lf%lf",
			&node[i].x,&node[i].y,&node[i].z,&node[i].r);
		p=0;
		for(i=0;i<n;i++) {
			for(j=i+1;j<n;j++) {
				edge[p].from=i;
				edge[p].to=j;
				edge[p].cost=sqrt(
					(node[i].x-node[j].x)*(node[i].x-node[j].x)+
					(node[i].y-node[j].y)*(node[i].y-node[j].y)+
					(node[i].z-node[j].z)*(node[i].z-node[j].z)
				)-node[i].r-node[j].r;
				if(edge[p].cost<=0)edge[p].cost=0;
				p++;
			}
		}
		qsort(edge,p,sizeof(edge_t),qsort_comp);
		c=1;
		result=0;
		uf_init();
		for(i=0;i<p && c<n;i++) {
			if(!uf_issame(edge[i].from,edge[i].to)) {
				c++;
				result+=edge[i].cost;
				uf_merge(edge[i].from,edge[i].to);
			}
		}
		printf("%.3f\n",result);
	}
	return 0;
}
3
10.000 10.000 50.000 10.000
40.000 10.000 50.9661040800581 10.000
40.000 40.000 50.000 10.000
2
30.000 30.000 30.000 20.000
40.000 40.000 40.000 20.000
5
5.729 15.143 3.996 25.837
6.013 14.372 4.818 10.671
80.115 63.292 84.477 15.120
64.095 80.924 70.029 14.881
39.472 85.116 71.369 5.553
0
 3
10.000 10.000 50.000 10.000
40.000 10.000 50.9661040800581 10.000
40.000 40.000 50.000 10.000
2
30.000 30.000 30.000 20.000
40.000 40.000 40.000 20.000
5
5.729 15.143 3.996 25.837
6.013 14.372 4.818 10.671
80.115 63.292 84.477 15.120
64.095 80.924 70.029 15.74744436670293
39.472 85.116 71.369 5.553
0
 3
10.000 10.000 50.000 10.000
40.000 10.000 50.9661040800581 10.000
40.000 40.000 50.000 10.000
2
30.000 30.000 30.000 20.000
40.000 40.000 40.000 20.000
5
5.729 15.143 3.996 25.837
6.013 14.372 4.818 10.671
80.115 63.292 84.96291652289682 15.120
64.095 80.924 70.029 15.74744436670293
39.472 85.116 72.06363785181492 5.553
0
 3
10.000 10.000 50.000 10.000
40.000 10.000 50.9661040800581 10.000
40.000 40.000 50.000 10.000
2
30.000 30.000 30.000 20.000
40.000 40.000 40.000 20.000
5
5.729 15.143 3.996 25.837
6.013 14.372 4.818 11.285102790232827
80.115 63.292 84.96291652289682 15.120
64.095 80.924 70.029 15.74744436670293
39.472 85.116 72.67566488438055 5.553
0
 3
10.000 10.000 50.000 10.000
40.000 10.000 50.9661040800581 10.000
40.000 40.000 50.000 10.89540561727416
2
30.000 30.000 30.000 20.000
40.000 40.000 40.000 20.000
5
5.729 15.143 3.996 25.837
6.013 14.372 4.818 11.285102790232827
80.115 63.292 84.96291652289682 15.120
64.095 80.924 70.029 15.74744436670293
39.472 85.116 72.67566488438055 5.553
0
 3
10.000 10.000 50.000 10.000
40.000 10.000 51.219861131766976 10.000
40.000 40.000 50.000 10.89540561727416
2
30.000 30.000 30.787057368701163 20.000
40.000 40.000 40.000 20.000
5
5.729 15.143 3.996 25.837
6.013 14.372 4.818 12.169672589379822
80.115 63.292 84.96291652289682 15.120
64.095 80.924 70.029 15.74744436670293
39.472 85.116 72.67566488438055 5.553
0
 3
10.000 10.000 50.000 10.000
40.000 10.000 51.219861131766976 10.000
40.000 40.000 50.000 10.89540561727416
2
30.000 30.000 30.787057368701163 20.000
40.000 40.897526923182255 40.000 20.000
5
5.729 15.143 4.635408214127903 25.837
6.013 14.372 4.818 12.169672589379822
80.115 63.292 84.96291652289682 15.120
64.095 80.924 70.029 15.74744436670293
39.472 85.116 72.67566488438055 5.553
0
 3
10.000 10.000 50.000 10.000
40.000 10.000 51.219861131766976 10.000
40.000 40.51646067399203 50.000 10.89540561727416
2
30.000 30.000 30.787057368701163 20.128299631926932
40.000 40.897526923182255 40.000 20.000
5
5.729 15.143 4.635408214127903 25.837
6.013 14.372 4.818 12.169672589379822
80.115 63.292 84.96291652289682 15.120
64.095 80.924 70.029 15.74744436670293
39.472 85.116 72.67566488438055 5.553
0
 3
10.000 10.000 50.000 10.000
40.000 10.000 51.219861131766976 10.000
40.000 40.51646067399203 50.343828752057796 10.89540561727416
2
30.571866538226903 30.000 30.787057368701163 20.128299631926932
40.000 40.897526923182255 40.000 20.000
5
5.729 15.143 4.635408214127903 25.837
6.013 14.372 5.37263216776346 12.169672589379822
80.115 63.292 84.96291652289682 15.120
64.095 80.924 70.029 15.74744436670293
39.472 85.116 72.67566488438055 5.553
0
 3
10.428063836405636 10.000 50.000 10.000
40.000 10.000 51.219861131766976 10.000
40.000 40.51646067399203 50.343828752057796 10.89540561727416
2
30.571866538226903 30.000 30.787057368701163 20.128299631926932
40.000 40.897526923182255 40.000 20.000
5
5.729 15.143 4.635408214127903 25.837
6.013 14.372 5.37263216776346 12.169672589379822
80.115 63.292 84.96291652289682 15.120
64.095 80.924 70.029 15.74744436670293
39.472 85.116 72.67566488438055 5.553
0

20.031
0.000
73.834
 20.031
0.000
72.101
 20.031
0.000
72.148
 20.031
0.000
72.205
 19.136
0.000
72.205
 19.154
0.000
72.205
 19.154
0.000
71.823
 19.670
0.000
71.823
 19.658
0.000
71.823
 19.231
0.000
71.823

Given the following C code and unoptimized assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include <stdio.h>
#include <stdlib.h>
#include <math.h>

#define UNION_FIND_MAX 100

int uf_table[UNION_FIND_MAX];

void uf_init(void) {
	int i;
	for(i=0;i<UNION_FIND_MAX;i++)uf_table[i]=0;
}

void uf_merge(int a,int b) {
	int next;
	while(uf_table[a]>0) {
		next=uf_table[a]-1;
		if(uf_table[next]>0)uf_table[a]=uf_table[next];
		a=next;
	}
	while(uf_table[b]>0) {
		next=uf_table[b]-1;
		if(uf_table[next]>0)uf_table[b]=uf_table[next];
		b=next;
	}
	if(a!=b)uf_table[a]=b+1;
}

int uf_issame(int a,int b) {
	int next;
	while(uf_table[a]>0) {
		next=uf_table[a]-1;
		if(uf_table[next]>0)uf_table[a]=uf_table[next];
		a=next;
	}
	while(uf_table[b]>0) {
		next=uf_table[b]-1;
		if(uf_table[next]>0)uf_table[b]=uf_table[next];
		b=next;
	}
	return a==b;
}

typedef struct {
	int from,to;
	double cost;
} edge_t;

typedef struct {
	double x,y,z,r;
} node_t;

int qsort_comp(const void* x,const void* y) {
	const edge_t* a=(const edge_t*)x;
	const edge_t* b=(const edge_t*)y;
	if((a->cost)>(b->cost))return 1;
	if((a->cost)<(b->cost))return -1;
	return 0;
}

int n;
node_t node[100];
edge_t edge[10000];

int main(void) {
	int i,j,p,c;
	double result;
	while(scanf("%d",&n)==1 && n>0) {
		for(i=0;i<n;i++)scanf("%lf%lf%lf%lf",
			&node[i].x,&node[i].y,&node[i].z,&node[i].r);
		p=0;
		for(i=0;i<n;i++) {
			for(j=i+1;j<n;j++) {
				edge[p].from=i;
				edge[p].to=j;
				edge[p].cost=sqrt(
					(node[i].x-node[j].x)*(node[i].x-node[j].x)+
					(node[i].y-node[j].y)*(node[i].y-node[j].y)+
					(node[i].z-node[j].z)*(node[i].z-node[j].z)
				)-node[i].r-node[j].r;
				if(edge[p].cost<=0)edge[p].cost=0;
				p++;
			}
		}
		qsort(edge,p,sizeof(edge_t),qsort_comp);
		c=1;
		result=0;
		uf_init();
		for(i=0;i<p && c<n;i++) {
			if(!uf_issame(edge[i].from,edge[i].to)) {
				c++;
				result+=edge[i].cost;
				uf_merge(edge[i].from,edge[i].to);
			}
		}
		printf("%.3f\n",result);
	}
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	uf_table
	.bss
	.align 32
	.type	uf_table, @object
	.size	uf_table, 400
uf_table:
	.zero	400
	.text
	.globl	uf_init
	.type	uf_init, @function
uf_init:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	$0, -4(%rbp)
	jmp	.L2
.L3:
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	$0, (%rdx,%rax)
	addl	$1, -4(%rbp)
.L2:
	cmpl	$99, -4(%rbp)
	jle	.L3
	nop
	nop
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	uf_init, .-uf_init
	.globl	uf_merge
	.type	uf_merge, @function
uf_merge:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	jmp	.L5
.L7:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L6
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L6:
	movl	-4(%rbp), %eax
	movl	%eax, -20(%rbp)
.L5:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L7
	jmp	.L8
.L10:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L9
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L9:
	movl	-4(%rbp), %eax
	movl	%eax, -24(%rbp)
.L8:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L10
	movl	-20(%rbp), %eax
	cmpl	-24(%rbp), %eax
	je	.L12
	movl	-24(%rbp), %eax
	leal	1(%rax), %ecx
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	%ecx, (%rdx,%rax)
.L12:
	nop
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	uf_merge, .-uf_merge
	.globl	uf_issame
	.type	uf_issame, @function
uf_issame:
.LFB8:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	jmp	.L14
.L16:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L15
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L15:
	movl	-4(%rbp), %eax
	movl	%eax, -20(%rbp)
.L14:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L16
	jmp	.L17
.L19:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L18
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L18:
	movl	-4(%rbp), %eax
	movl	%eax, -24(%rbp)
.L17:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L19
	movl	-20(%rbp), %eax
	cmpl	-24(%rbp), %eax
	sete	%al
	movzbl	%al, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	uf_issame, .-uf_issame
	.globl	qsort_comp
	.type	qsort_comp, @function
qsort_comp:
.LFB9:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movq	%rsi, -32(%rbp)
	movq	-24(%rbp), %rax
	movq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -8(%rbp)
	movq	-16(%rbp), %rax
	movsd	8(%rax), %xmm0
	movq	-8(%rbp), %rax
	movsd	8(%rax), %xmm1
	comisd	%xmm1, %xmm0
	jbe	.L29
	movl	$1, %eax
	jmp	.L24
.L29:
	movq	-16(%rbp), %rax
	movsd	8(%rax), %xmm1
	movq	-8(%rbp), %rax
	movsd	8(%rax), %xmm0
	comisd	%xmm1, %xmm0
	jbe	.L30
	movl	$-1, %eax
	jmp	.L24
.L30:
	movl	$0, %eax
.L24:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	qsort_comp, .-qsort_comp
	.globl	n
	.bss
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	node
	.align 32
	.type	node, @object
	.size	node, 3200
node:
	.zero	3200
	.globl	edge
	.align 32
	.type	edge, @object
	.size	edge, 160000
edge:
	.zero	160000
	.section	.rodata
.LC0:
	.string	"%lf%lf%lf%lf"
.LC2:
	.string	"%.3f\n"
.LC3:
	.string	"%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB10:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$32, %rsp
	jmp	.L32
.L46:
	movl	$0, -24(%rbp)
	jmp	.L33
.L34:
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	leaq	16(%rax), %rdx
	leaq	node(%rip), %rax
	addq	%rdx, %rax
	leaq	8(%rax), %rsi
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	leaq	16(%rax), %rdx
	leaq	node(%rip), %rax
	leaq	(%rdx,%rax), %rcx
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	addq	%rdx, %rax
	leaq	8(%rax), %rdx
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdi
	leaq	node(%rip), %rax
	addq	%rdi, %rax
	movq	%rsi, %r8
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -24(%rbp)
.L33:
	movl	n(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L34
	movl	$0, -16(%rbp)
	movl	$0, -24(%rbp)
	jmp	.L35
.L40:
	movl	-24(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -20(%rbp)
	jmp	.L36
.L39:
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	edge(%rip), %rdx
	movl	-24(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	4+edge(%rip), %rdx
	movl	-20(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm2
	movapd	%xmm0, %xmm1
	subsd	%xmm2, %xmm1
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm2
	subsd	%xmm2, %xmm0
	mulsd	%xmm0, %xmm1
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	movapd	%xmm0, %xmm2
	subsd	%xmm3, %xmm2
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	subsd	%xmm3, %xmm0
	mulsd	%xmm2, %xmm0
	addsd	%xmm0, %xmm1
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	movapd	%xmm0, %xmm2
	subsd	%xmm3, %xmm2
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	subsd	%xmm3, %xmm0
	mulsd	%xmm2, %xmm0
	addsd	%xmm0, %xmm1
	movq	%xmm1, %rax
	movq	%rax, %xmm0
	call	sqrt@PLT
	movq	%xmm0, %rax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	movq	%rdx, %rcx
	salq	$5, %rcx
	leaq	24+node(%rip), %rdx
	movsd	(%rcx,%rdx), %xmm1
	movq	%rax, %xmm0
	subsd	%xmm1, %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	24+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm1
	subsd	%xmm1, %xmm0
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	movsd	%xmm0, (%rdx,%rax)
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	movsd	(%rdx,%rax), %xmm1
	pxor	%xmm0, %xmm0
	comisd	%xmm1, %xmm0
	jb	.L37
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	pxor	%xmm0, %xmm0
	movsd	%xmm0, (%rdx,%rax)
.L37:
	addl	$1, -16(%rbp)
	addl	$1, -20(%rbp)
.L36:
	movl	n(%rip), %eax
	cmpl	%eax, -20(%rbp)
	jl	.L39
	addl	$1, -24(%rbp)
.L35:
	movl	n(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L40
	movl	-16(%rbp), %eax
	cltq
	leaq	qsort_comp(%rip), %rdx
	movq	%rdx, %rcx
	movl	$16, %edx
	movq	%rax, %rsi
	leaq	edge(%rip), %rax
	movq	%rax, %rdi
	call	qsort@PLT
	movl	$1, -12(%rbp)
	pxor	%xmm0, %xmm0
	movsd	%xmm0, -8(%rbp)
	call	uf_init
	movl	$0, -24(%rbp)
	jmp	.L41
.L44:
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+edge(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	edge(%rip), %rax
	movl	(%rcx,%rax), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	uf_issame
	testl	%eax, %eax
	jne	.L42
	addl	$1, -12(%rbp)
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movsd	-8(%rbp), %xmm1
	addsd	%xmm1, %xmm0
	movsd	%xmm0, -8(%rbp)
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+edge(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	edge(%rip), %rax
	movl	(%rcx,%rax), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	uf_merge
.L42:
	addl	$1, -24(%rbp)
.L41:
	movl	-24(%rbp), %eax
	cmpl	-16(%rbp), %eax
	jge	.L43
	movl	n(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L44
.L43:
	movq	-8(%rbp), %rax
	movq	%rax, %xmm0
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$1, %eax
	call	printf@PLT
.L32:
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	cmpl	$1, %eax
	jne	.L45
	movl	n(%rip), %eax
	testl	%eax, %eax
	jg	.L46
.L45:
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
train
	.file	"temp.c"
	.text
	.globl	uf_table
	.bss
	.align 32
	.type	uf_table, @object
	.size	uf_table, 400
uf_table:
	.zero	400
	.text
	.globl	uf_init
	.type	uf_init, @function
uf_init:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	$0, -4(%rbp)
	jmp	.L2
.L3:
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	$0, (%rdx,%rax)
	addl	$1, -4(%rbp)
.L2:
	cmpl	$99, -4(%rbp)
	jle	.L3
	nop
	nop
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	uf_init, .-uf_init
	.globl	uf_merge
	.type	uf_merge, @function
uf_merge:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	jmp	.L5
.L7:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L6
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L6:
	movl	-4(%rbp), %eax
	movl	%eax, -20(%rbp)
.L5:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L7
	jmp	.L8
.L10:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L9
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L9:
	movl	-4(%rbp), %eax
	movl	%eax, -24(%rbp)
.L8:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L10
	movl	-20(%rbp), %eax
	cmpl	-24(%rbp), %eax
	je	.L12
	movl	-24(%rbp), %eax
	leal	1(%rax), %ecx
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	%ecx, (%rdx,%rax)
.L12:
	nop
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	uf_merge, .-uf_merge
	.globl	uf_issame
	.type	uf_issame, @function
uf_issame:
.LFB8:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	jmp	.L14
.L16:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L15
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L15:
	movl	-4(%rbp), %eax
	movl	%eax, -20(%rbp)
.L14:
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L16
	jmp	.L17
.L19:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	subl	$1, %eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jle	.L18
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	uf_table(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
.L18:
	movl	-4(%rbp), %eax
	movl	%eax, -24(%rbp)
.L17:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	uf_table(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jg	.L19
	movl	-20(%rbp), %eax
	cmpl	-24(%rbp), %eax
	sete	%al
	movzbl	%al, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	uf_issame, .-uf_issame
	.globl	qsort_comp
	.type	qsort_comp, @function
qsort_comp:
.LFB9:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movq	%rsi, -32(%rbp)
	movq	-24(%rbp), %rax
	movq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -8(%rbp)
	movq	-16(%rbp), %rax
	movsd	8(%rax), %xmm0
	movq	-8(%rbp), %rax
	movsd	8(%rax), %xmm1
	comisd	%xmm1, %xmm0
	jbe	.L29
	movl	$1, %eax
	jmp	.L24
.L29:
	movq	-16(%rbp), %rax
	movsd	8(%rax), %xmm1
	movq	-8(%rbp), %rax
	movsd	8(%rax), %xmm0
	comisd	%xmm1, %xmm0
	jbe	.L30
	movl	$-1, %eax
	jmp	.L24
.L30:
	movl	$0, %eax
.L24:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	qsort_comp, .-qsort_comp
	.globl	n
	.bss
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	node
	.align 32
	.type	node, @object
	.size	node, 3200
node:
	.zero	3200
	.globl	edge
	.align 32
	.type	edge, @object
	.size	edge, 160000
edge:
	.zero	160000
	.section	.rodata
.LC0:
	.string	"%lf%lf%lf%lf"
.LC2:
	.string	"%.3f\n"
.LC3:
	.string	"%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB10:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$32, %rsp
	jmp	.L32
.L46:
	movl	$0, -24(%rbp)
	jmp	.L33
.L34:
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	leaq	16(%rax), %rdx
	leaq	node(%rip), %rax
	addq	%rdx, %rax
	leaq	8(%rax), %rsi
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	leaq	16(%rax), %rdx
	leaq	node(%rip), %rax
	leaq	(%rdx,%rax), %rcx
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	addq	%rdx, %rax
	leaq	8(%rax), %rdx
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdi
	leaq	node(%rip), %rax
	addq	%rdi, %rax
	movq	%rsi, %r8
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -24(%rbp)
.L33:
	movl	n(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L34
	movl	$0, -16(%rbp)
	movl	$0, -24(%rbp)
	jmp	.L35
.L40:
	movl	-24(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -20(%rbp)
	jmp	.L36
.L39:
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	edge(%rip), %rdx
	movl	-24(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	4+edge(%rip), %rdx
	movl	-20(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm2
	movapd	%xmm0, %xmm1
	subsd	%xmm2, %xmm1
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	node(%rip), %rax
	movsd	(%rdx,%rax), %xmm2
	subsd	%xmm2, %xmm0
	mulsd	%xmm0, %xmm1
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	movapd	%xmm0, %xmm2
	subsd	%xmm3, %xmm2
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	8+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	subsd	%xmm3, %xmm0
	mulsd	%xmm2, %xmm0
	addsd	%xmm0, %xmm1
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	movapd	%xmm0, %xmm2
	subsd	%xmm3, %xmm2
	movl	-24(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	16+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm3
	subsd	%xmm3, %xmm0
	mulsd	%xmm2, %xmm0
	addsd	%xmm0, %xmm1
	movq	%xmm1, %rax
	movq	%rax, %xmm0
	call	sqrt@PLT
	movq	%xmm0, %rax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	movq	%rdx, %rcx
	salq	$5, %rcx
	leaq	24+node(%rip), %rdx
	movsd	(%rcx,%rdx), %xmm1
	movq	%rax, %xmm0
	subsd	%xmm1, %xmm0
	movl	-20(%rbp), %eax
	cltq
	salq	$5, %rax
	movq	%rax, %rdx
	leaq	24+node(%rip), %rax
	movsd	(%rdx,%rax), %xmm1
	subsd	%xmm1, %xmm0
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	movsd	%xmm0, (%rdx,%rax)
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	movsd	(%rdx,%rax), %xmm1
	pxor	%xmm0, %xmm0
	comisd	%xmm1, %xmm0
	jb	.L37
	movl	-16(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	pxor	%xmm0, %xmm0
	movsd	%xmm0, (%rdx,%rax)
.L37:
	addl	$1, -16(%rbp)
	addl	$1, -20(%rbp)
.L36:
	movl	n(%rip), %eax
	cmpl	%eax, -20(%rbp)
	jl	.L39
	addl	$1, -24(%rbp)
.L35:
	movl	n(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L40
	movl	-16(%rbp), %eax
	cltq
	leaq	qsort_comp(%rip), %rdx
	movq	%rdx, %rcx
	movl	$16, %edx
	movq	%rax, %rsi
	leaq	edge(%rip), %rax
	movq	%rax, %rdi
	call	qsort@PLT
	movl	$1, -12(%rbp)
	pxor	%xmm0, %xmm0
	movsd	%xmm0, -8(%rbp)
	call	uf_init
	movl	$0, -24(%rbp)
	jmp	.L41
.L44:
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+edge(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	edge(%rip), %rax
	movl	(%rcx,%rax), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	uf_issame
	testl	%eax, %eax
	jne	.L42
	addl	$1, -12(%rbp)
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+edge(%rip), %rax
	movsd	(%rdx,%rax), %xmm0
	movsd	-8(%rbp), %xmm1
	addsd	%xmm1, %xmm0
	movsd	%xmm0, -8(%rbp)
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+edge(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	edge(%rip), %rax
	movl	(%rcx,%rax), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	uf_merge
.L42:
	addl	$1, -24(%rbp)
.L41:
	movl	-24(%rbp), %eax
	cmpl	-16(%rbp), %eax
	jge	.L43
	movl	n(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L44
.L43:
	movq	-8(%rbp), %rax
	movq	%rax, %xmm0
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$1, %eax
	call	printf@PLT
.L32:
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	cmpl	$1, %eax
	jne	.L45
	movl	n(%rip), %eax
	testl	%eax, %eax
	jg	.L46
.L45:
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
