I would say both are useable grammically. But "compare between x and y" can be used to make more complex sentences. ", which sentence do you think is more sophisticated^^?
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.