Smallest Even number with N digits | Function to return smallest even number with n digits ; Driver Code
< ? php function smallestEven ( $ n ) { if ( $ n == 1 ) return 0 ; return pow ( 10 , $ n - 1 ) ; } $ n = 4 ; echo smallestEven ( $ n ) ; ? >