2367. Number of Arithmetic Triplets (Leetcode Easy)