human
Number with even sum of digits | Function to find kth good number ..
Find the last digit of n ..
If last digit is between 0 to 4 then return 2 * n ..
If last digit is between 5 to 9 then return 2 * n + 1..
Driver code"
How can the above be solved in Python?
 What is a code to number with even sum of digits and the other steps required?
assistant
#Here is code to number with even sum of digits and the other steps required.
 def findKthGoodNo ( n ) :
	lastDig = n % 10
	if ( lastDig >= 0 and lastDig <= 4 ) :
		return n << 1
	else :
		return ( n << 1 ) + 1
n = 10
print ( findKthGoodNo ( n ) )