Optimization!!

BTW TS1501 if you're cherry-picking from my codes, give proper credits or else!