Chapter 6 Example 6

by actionscriptbible
♥0 | Line 13 | Modified 2010-01-20 18:11:09 | MIT License
play

ActionScript3 source code

/**
 * Copyright actionscriptbible ( http://wonderfl.net/user/actionscriptbible )
 * MIT License ( http://www.opensource.org/licenses/mit-license.php )
 * Downloaded from: http://wonderfl.net/c/t3gg
 */

package {
  import com.actionscriptbible.Example;
  public class ch6ex6 extends Example {
    public function ch6ex6() {
      //"Peace"
      var jp:String = "平和";
      var he:String = "שלם";
      var ar:String = "سلام";

      trace(jp, he, ar);

      //Your editor may display these strings right-to-left, but they are still stored from index 0 up.
      trace(he.charAt(2)); //ם
      //ActionScript Regular Expressions are Unicode-safe!
      trace(jp.match(/和/));
    }
  }
}

Forked