Find the largest N digit multiple of N | Function to find the largest N digit multiple of N ; Driver code
function smallestNumber ( N ) { document . write ( N * Math . floor ( ( Math . pow ( 10 , N ) - 1 ) / N ) ) ; } let N = 2 ; smallestNumber ( N ) ;