Program to find Star number | C # program to find star number ; Returns n - th star number ; Driver code
using System ; class GFG { static int findStarNum ( int n ) { return ( 6 * n * ( n - 1 ) + 1 ) ; } public static void Main ( ) { int n = 3 ; Console . Write ( findStarNum ( n ) ) ; } }