all groups > flash actionscript > april 2007 >
You're in the

flash actionscript

group:

swapping values of two vars


Re: swapping values of two vars Raymond Basque
4/20/2007 3:14:44 PM
flash actionscript:
rotfl. The interview must not have went well :)

Re: swapping values of two vars Raymond Basque
4/20/2007 3:16:26 PM
Discussed yesterday. Search the forum.

swapping values of two vars Vee
4/20/2007 6:08:25 PM
is it possbile to simutaneously swap two values of vars
ex:
var me:Number=1;
var you:Number=0;
_root.me.swap[you]
trace('me: '+me+'\n'+'you: +you);
/*result:
me: 0
you: 1
*/
Is this possible... im guessing its just this easy.
Re: swapping values of two vars kglad
4/20/2007 7:00:30 PM
Re: swapping values of two vars Vee
4/20/2007 7:13:08 PM
Re: swapping values of two vars GWD
4/20/2007 7:22:19 PM
I don't think it was a negative comment, well at least not one directed at you
anyway.

It was (as I interpreted it) a comment directed at the type of company that
would require you to know something like this in an interview in order to be
considered as a potential candidate. Its almost an academic style challenge,
without (in my opinion) a lot of practical benefit.

That said, I (and a couple of others) enjoyed the distraction it offered when
someone else asked recently. I think this link should take you there.


http://www.adobe.com/cfusion/webforums/forum/messageview.cfm?forumid=15&catid=28
8&threadid=1260959&enterthread=y

Re: swapping values of two vars Vee
4/20/2007 7:40:54 PM
Thats great. I thought this would be something that everyone uses and I just
hadnt got around to implementing it. And for the record I wasn't going out for
that job, I am using it for a slideshow that use two mc with a back and forward
button. Given the order of events the user either keeps the existing holder and
loads a new image into it or switches to the other holder to load into.
thanks for your help again, see you around.

Hope he got his job =)
Re: swapping values of two vars GWD
4/20/2007 7:43:36 PM
Re: swapping values of two vars Vee
4/20/2007 7:52:18 PM
Re: swapping values of two vars kglad
4/20/2007 7:58:07 PM
i can't think of a more useless piece of information (related to flash) than
swapping variable values without creating a third variable. i don't even think
this would have been useful in the days when ram was limited to 64k.
Re: swapping values of two vars Vee
4/20/2007 8:06:23 PM
AddThis Social Bookmark Button