Uncommented daniel's code"