Count all possible N digit numbers that satisfy the given condition | Function to return the count of required numbers ; If N is odd then return 0 ; Driver Code
< ? php function getCount ( $ N ) { if ( $ N % 2 == 1 ) return 0 ; $ result = "9" ; for ( $ i = 1 ; $ i <= $ N / 2 - 1 ; $ i ++ ) $ result . = "0" ; return $ result ; } $ N = 4 ; echo getCount ( $ N ) ; ? >