using System; class Program { static void Main(string[] args) { Console.WriteLine("Hello, world!"); } }
append("apple"); $array->append("orange"); $array->append("banana"); foreach ($array as $value) { echo $value . "\n"; } ?>This example shows how to create a new PhpArray object, add elements to it using the `append()` method, and then loop through the array using a `foreach` loop. Each element is printed to the screen using `echo`. Package library: PhpArray is a part of the PHPLinq library, which provides a set of classes and functions for working with arrays and collections in PHP.