python - Rampfunction code -


i'm trying solve problem: create function reproduces rampfuntion

                     n, n >= 0                  r(n)=                      0, n < 0 

can help?

you gave python tag, i'll in python.

ramp = lambda x: x if x >= 0 else 0 

Comments

Popular posts from this blog

1111. appearing after print sequence - php -

node.js - Express and Redis - If session exists for this user, don't allow access -

excel - I can't get the attachement of the email PHP -