Mar-12-2025, 04:16 PM
(This post was last modified: Mar-12-2025, 05:40 PM by deanhystad.)
def compost(soil): if soil < 15: return soil + 10 else: return soil + 5 def mulch(soil): new_soil = soil + 3 if new_soil > 25: new_soil *= 1.2 return round(new_soil) def final_soil(soil): final = mulch(compost(soil)) return round(final) final = final_soil(20) print("Final soil value:", final)hmmm - this does not appear to work. I copied some code from a working python script in IDLE. Replied via this message. Clicked the python inserts. Pasted my code between them. Viewing it in Preview, it does not appear to have formatted correctly- everything is left justified, and no colours.