Python code to compare languages for similarities