You can compare things like memory, internal storage, processor, camera, screen size etc to give you an idea which phone is technically more advanced. You should then try to get your hands on each to see which appears to have the better build quality.
The next - and possibly more important - question is what each phone does best and here it's always horses for courses: which phone is better for you depends on what you want to use it for ..