Two Horses
On a standard chessboard (8×8), there are 2 chess knights: one Red and one Green. Typically, they roam freely across the board, enjoying their time. However, today is special—it's the Green knight's birthday. To celebrate, the Green knight wants to meet up with the Red knight on the same square. Unlike traditional black and white knights, these knights move simultaneously and can share the same square without capturing each other. Your task is to determine the minimum number of moves required for them to meet on the same square, or determine if it's impossible.
Input
The input provides the starting coordinates of both knights, formatted according to standard chess notation: a lowercase letter (from a to h) followed by a digit (from 1 to 8), indicating the column and row respectively.
Output
The output should be the minimum number of moves needed for the knights to meet, or -1 if they cannot meet.