human
Print all 3 digit repeating numbers in a very large number | Function to print 3 digit repeating numbers.
Hashmap to store the frequency of a 3 digit number.
first three digit number.
if key already exists increase value by 1.
Output the three digit numbers with frequency > 1.
Driver Code.
Input string.
Calling Function"
Solution in Python:

Can you provide a code to print all 3 digit repeating numbers in a very large number and the other steps required?
assistant
#Here is code to print all 3 digit repeating numbers in a very large number and the other steps required.
 def printNum ( s ) :
	i , j , val = 0 , 0 , 0
	mp = { }
	val = ( ( ord ( s [ 0 ] ) - ord ( '0' ) ) * 100 + ( ord ( s [ 1 ] ) - ord ( '0' ) ) * 10 + ( ord ( s [ 2 ] ) - ord ( '0' ) ) )
	mp [ val ] = 1
	for i in range ( 3 , len ( s ) ) :
		val = ( val % 100 ) * 10 + ord ( s [ i ] ) - ord ( '0' )
		if ( val in mp ) :
			mp [ val ] = mp [ val ] + 1
		else :
			mp [ val ] = 1
	for m in mp :
		key = m
		value = mp [ m ]
		if ( value > 1 ) :
			print ( key , " ▁ - ▁ " , value , " ▁ times " )
if __name__ == " _ _ main _ _ " :
	input = "123412345123456"
	printNum ( input )