human
Can you provide a code to count of Missing Numbers in a sorted array and the other steps required given the following:
Count of Missing Numbers in a sorted array | Function that find the count of missing numbers in array a [ ].
Calculate the count of missing numbers in the array.
Driver Code"
Solution in Python:
assistant
#Here is code to count of Missing Numbers in a sorted array and the other steps required.
 def countMissingNum ( a , N ) :
	count = a [ N - 1 ] - a [ 0 ] + 1 - N
	print ( count )
arr = [ 5 , 10 , 20 , 40 ]
N = len ( arr )
countMissingNum ( arr , N )