There are $1000$ students in a school. Every student has exactly $4$ friends. A group of three students $ \left \{A,B,C \right \}$ is said to be a [i]friendly triplet[/i] if any two students in the group are friends. Determine the maximal possible number of friendly triplets.

[i]Proposed by Nikola Velov[/i]
1. **Graph Interpretation**:
   - Consider the problem in terms of graph theory. Let \( G \) be a graph where each vertex represents a student and each edge represents a friendship.
   - Given that there are \( n = 1000 \) students and each student has exactly \( d = 4 \) friends, \( G \) is a 4-regular graph with 1000 vertices.

2. **Counting Triangles**:
   - A *friendly triplet* corresponds to a triangle in the graph \( G \).
   - For a vertex \( v \) in \( G \), the number of triangles that include \( v \) is determined by the number of edges between the neighbors of \( v \).
   - Since \( v \) has 4 neighbors, the number of edges between these neighbors is at most \( \binom{4}{2} = 6 \).

3. **Total Number of Triangles**:
   - Each triangle in \( G \) is counted three times (once at each vertex of the triangle).
   - Therefore, the total number of triangles in \( G \) is at most:
     \[
     \frac{1}{3} \sum_{v \in V(G)} \binom{d}{2}
     \]
   - Since \( G \) is 4-regular, each vertex \( v \) has exactly 4 neighbors, and thus:
     \[
     \binom{4}{2} = 6
     \]
   - The sum over all vertices is:
     \[
     \sum_{v \in V(G)} \binom{4}{2} = 1000 \times 6 = 6000
     \]
   - Dividing by 3 to account for the overcounting of each triangle:
     \[
     \frac{6000}{3} = 2000
     \]

4. **Achievability**:
   - The equality case occurs when \( G \) can be decomposed into disjoint copies of \( K_5 \) (the complete graph on 5 vertices), as each \( K_5 \) contains exactly \( \binom{5}{3} = 10 \) triangles.
   - Since \( K_5 \) is 4-regular and has 5 vertices, we can have \( \frac{1000}{5} = 200 \) copies of \( K_5 \).
   - Each \( K_5 \) contributes 10 triangles, so the total number of triangles is:
     \[
     200 \times 10 = 2000
     \]

Conclusion:
\[
\boxed{2000}
\]