Use endswith
Improvements..