Inserting Elements in the Middle of an Array : Array Declaration : Array Flash / Flex / ActionScript examples


Flash / Flex / ActionScript examples » Array » Array Declaration »

 

Inserting Elements in the Middle of an Array


 

package{
  import flash.display.Sprite;
  
  public class Main extends Sprite{
    public function Main(){
        var letters:Array = ["a""b""c""d"];
             
        letters.splice(10"r""s""t");
             
        for (var i:int 0; i < letters.length; i++) {
            trace(letters[i]);
        }
    }
  }
}
a
r
s
t
b
c
d

        



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


Flash / Flex / ActionScript examples

 Navioo Array
» Array Declaration