Not all functions have parameters. Programs that control robots use functions that do not return any calculated result, but instead move arms, walk, and so on. Showing a robot function is not so easy, and instead demonstrate with print statements. The return None statements in the example could be removed, however the chapter makes it clear that None would be the default returned value anyway.


Control Functions

def functionA():
  print "A",
  return None
def functionB():
  print "B",
  functionA()
  functionA()
  print "B",
  return None
functionB()
functionB()
print "C"