Redefined. Simplified for understandability. Improved. Still not working