x,y,d = map(int,input().split()) print(max(0,y+x-d+1))