#include using namespace std; typedef long long ll; ll mod=1000000007; int main(){ ll n,k;cin>>n>>k; if(k==0){ ll s=1; for(ll i=1;i<=n;i++){ s*=i; s%=mod; } cout<>a[i]; sort(a,a+n); ll sum=0; ll ans=1; for(ll i=0;i=1;y--){ ans*=y; ans%=mod; } sum=a[i]; } ll x=__builtin_popcount(a[k-1]); for(ll i=n-x;i>=1;i--){ ans*=i; ans%=mod; } cout<