Version with no errors but the io doesn't seem to be evaluated correctly