The delete operator can be used to remove key-value pairs from an associative array.
The delete operator returns true if deletion succeeds.
package{
import flash.display.Sprite;
publicclass Main extends Sprite{
public function Main(){
var pastas:Object = {t: 2, g: 14, s: 9};
trace(pastas["s"]); // Displays 9
delete pastas["s"];
trace(pastas["s"]); // Displays undefined
}
}
}