Bug correction in lambda calculation