Advertisement
Guest User

Untitled

a guest
Jan 19th, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.47 KB | None | 0 0
  1. # Import Robot class to use the methods within
  2. from Robot import *
  3.  
  4. # Create Robot1 object with arguments
  5. Robot1 = Robot.one_string('Altman-X27-Cobalt')
  6. # Call the robotInfo function using the Robot2 object
  7. Robot1.robotInfo()
  8. # Set state variable equal to return value from check class
  9. state = Robot.check()
  10. # Call methods depending on value of state
  11. if state == 'Y':
  12.     Robot.sleep()
  13. elif state == 'N':
  14.     Robot.fetch()
  15. else:
  16.     print('Error, invalid percepts.')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement