Function that returns nth Fibonacci number
static long fib ( long n , long m ) { long F [ ] [ ] = { { 1 , 1 } , { 1 , 0 } } ; if ( n == 0 ) return 0 ; power ( F , n - 1 , m ) ; return F [ 0 ] [ 0 ] ; }