By Charles

Code needs optimization for better performance.