a,b,n=gets.split.map &:to_i t=1 [*a..b].repeated_permutation(n){|i|t=t*i.reduce(:gcd)%(10**9+7)} p t