added debug variable and apples; close #35, close #32