(a-b)2+(b-c)2+(c-a)2=4(a2+b2+c2-ab-ac-bc)
=>a2-2ab+b2+b2-2bc+c2+c2-2ac+a2=4a2+4b2+4c2-4ab-4ac-4bc
=>2a2+2b2+2c2-2ab-2ac-2bc=4a2+4b2+4c2-4ab-4ac-4bc
=>2a2+2b2+2c2-2ab-2ac-2bc-4a2-4b2-4c2+4ab+4bc+4ac=0
=>-2a2-2b2-2c2+2ab+2ac+2bc=0
=>-(2a2+2b2+2c2-2ab-2ac-2bc)=0
=>-[(a2-2ab+b2)+(b2-2bc+c2)+(a2-2ac+c2)]=0
=>-[(a-b)2+(b-c)2+(a-c)2]=0
=>(a-b)2+(b-c)2+(a-c)2=0
=>(a-b)=(b-c)=(a-c)=0
=>a-b=0 =>a=b (1)
b-c=0 =>b=c (2)
từ (1) và (2)
=>a=b=c (đpcm)