SPOJ problem - SUBSUMS

I was expecting TLE in the below implementation for SUBSUMS problem but I am getting WA please tell me where i’m making mistake. Thanks!!

Link of code:

Hey @rishit517
Here

int range = 1 << n;

Since n can be 34
So do this

int range = 1ll << n; (those are LL)

Otheriwse 1 is an int and 1<<34 will overflow
Now u will get TLE :slight_smile: