this is execution 5
*/
The following example uses ++ as a pre-increment operator:
var a:Array = [];
// var a:Array = new Array();
var i:Number = 0;
while (i<10) {
a.push(++i);
}
trace(a.toString());//traces: 1,2,3,4,5,6,7,8,9,10
This example also uses ++ as a pre-increment operator.
var a:Array = [];
for (var i = 1; i<=10; ++i) {
a.push(i);
}
trace(a.toString());//traces: 1,2,3,4,5,6,7,8,9,10
This script writes the following result to the log file:
1,2,3,4,5,6,7,8,9,10
The following example uses ++ as a post-increment operator in a
// using a while loop
var a:Array = [];
// var a:Array = new Array();
var i:Number = 0;
while (i<10) {
a.push(i++);
}
trace(a.toString());//traces 0,1,2,3,4,5,6,7,8,9
The following example uses ++ as a post-increment operator in a
// using a for loop
var a:Array = [];
// var a:Array = new Array();
for (var i = 0; i<10; i++) {
a.push(i);
}
trace(a.toString());//traces 0,1,2,3,4,5,6,7,8,9
This script writes the following result to the log file:
0,1,2,3,4,5,6,7,8,9
! (logical NOT)
Availability
Flash Player 4.
Usage
!expression
loop:
while
loop:
for
! (logical NOT)
83
Need help?
Do you have a question about the FLEX-FLEX ACTIONSCRIPT LANGUAGE and is the answer not in the manual?