Count of Unique Direct Path Between N Points On a Plane | C # program for the above approach ; Function to count the total number of direct paths ; Driver Code
using System ; public class GFG { static int countDirectPath ( int N ) { return N + ( N * ( N - 3 ) ) / 2 ; } public static void Main ( string [ ] args ) { int N = 5 ; Console . Write ( countDirectPath ( N ) ) ; } }