Alice Community  

Go Back   Alice Community > Alice 2 > How do I...?

Thread Tools Display Modes
Passing parameters between methods.
Posts: n/a
Default Passing parameters between methods. - 11-20-2006, 09:01 PM

My team is programming a game of tic-tac-toe. To keep track of X/Y turns we are using a parameter named counter. We can pass counter forward from the control method along to as many called methods as we want. The problem is that when we increment counter within a method (counter=counter+1) the returned value that we get in the method is not being passed back out to the control method. How do you pass these parameters back and forth properly?

I appreciate you time.
Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Copyright ©2019, Carnegie Mellon University
Alice 2.x 1999-2012, Alice 3.x 2008-2012, Carnegie Mellon University. All rights reserved.