The language’s built-in types should be trivial, but they’re not. There are a lot of little details overlooked by many programmers. Today’s article continues the series by looking at subtleties found in seemingly-obvious language features like strings and integers. Read on to learn some tricks!
Posts Tagged character
When a recent comment asked about string concatenation performance, I realized that there are a lot of ways to build strings in AS3 and I hadn’t tested any of them. Leaving aside the sillier ones like the XML class or joining
Array objects, we have two serious contenders: the lowly
+ operator (i.e.
str + str) and the
ByteArray class. Which will triumph as the ultimate way to build strings quickly?