very easy cpp solution ||   98 % faster
\nclass Solution {\npublic:\n    \n    \n    \n    int numSubseq(vector<int>& nums, int target) {\n        long long power[100005], ans=0,n=nums.size();;\n     
```\nclass Solution {\npublic:\n    \n    \n    \n    int numSubseq(vector<int>& nums, int target) {\n        long long power[100005], ans=0,n=nums.size();;\n        \n        power[0]=1;\n        for(int i=1;i<n;i++)\n        power[i]=(power[i-1]*2)%1000000007;\n        \n        sort(nums.begin(),nums.end());\n        int start=0,end=n-1;\n        while(start<=end)\n        {\n            if(nums[start]+nums[end]<=target)\n            {\n                ans+=power[end-start];\n                start++;\n            }\n            else\n                end--;\n            ans%=1000000007;\n            \n        }\n        return ans;\n    }\n};\n```
[]