This is the problem
Implement a function called get_direction which, on a particular character
, gives the
direction corresponding to that character. The correspondences are as
follows:
The character ’w’ corresponds to the direction ’North’
The character ’a’ corresponds to the direction ’West’
function:
def gallons_to_cups(quant):
"""
Takes quantity 'quant' in Gallons and computes and
returns the equivalent Cup quantity
"""
return 16 * quant + 0
what am i doing wrong?
On Thu, Mar 7, 2013 at 4:28 PM, akuma ukpo wrote:
>
llons to cups in a similar format.
On Thu, Mar 7, 2013 at 4:14 PM, Danny Yoo wrote:
> On Thu, Mar 7, 2013 at 1:55 PM, akuma ukpo wrote:
> > i don't know how to write functions. so i guess that is where i'm stuck.
> i
> > was following a tutorial on my lab document
I have a python lab to do but for some reason i can't understand.
(a) Write a function which converts from gallons to cups2
(b) Now we’d like to be able to convert from cups to milliliters, since
metric measurements
are easier to convert between. Implement a function which does this.
(c) We’d als