Find the Nth Hogben Numbers | Java program to print N - th Hogben Number ; Function returns N - th Hogben Number ; Driver code
import java . util . * ; class GFG { public static int HogbenNumber ( int a ) { int p = ( int ) ( Math . pow ( a , 2 ) - a + 1 ) ; return p ; } public static void main ( String args [ ] ) { int N = 10 ; System . out . print ( HogbenNumber ( N ) ) ; } }