#I tried solving this and got stuck. I still dont understand python that well.

6 messages · Page 1 of 1 (latest)

trim river
#

import lasagna

EXPECTED_BAKE_TIME =40 #in minutes
def remaining_bake_time(30):(elasped_time)
return = EXPECTED_BAKE_TIME-elasped time
PREPARATION_TIME_PER_LAYER =2 #in minutes
def preparation_time(number_of_layers):
return number_of_layers*PREPARATION_TIME_PER_LAYER

def total_elasped_cooking_time(number_of_layers

full lynx
#

Please use "code blocks" for pieces of code and error messages. Otherwise your code might not get rendered properly.
Also, if you got an error, post the error message, too.

keen pagodaBOT
full lynx
#

Two things:

  • There's an import lasagna at the top. What is it supposed to do? Do you need it?
  • Compare the two return statements. One starts with return = ..., the other with return .... Do you see the difference? Which one is syntactically correct?
full lynx
#

@candid gulch I was trying to give a hint that it's not necessary because it's in the file lasagna.py so the import lasagna essentially tries to import itself. I'm not a big fan of cargo cult where you write some code without understanding it, just because you've seen it somewhere.

candid gulch
#

I will be more careful from now on. Sorry for bothering you.