Fixed faster running code