1. Array Minimum number is:".min($arr); echo "
Maximum number is:".max($arr); sort($arr); echo "
The sorted Array is:"; foreach($arr aS $value) { echo $value.","; } rsort($arr); echo "
The Reverse sorted array is:"; foreach($arr as $value) { echo $value.","; } array_pop($arr); echo "
After pop the array is:"; foreach($arr as $value) { echo $value.","; } array_push($arr ,'50'); echo "
After push the array is:"; foreach($arr as $value) { echo $value.","; } ?> 2.GCD LCM GCD and LCM

GCD and LCM Calculator





GCD is:

LCM is:
3. Constructor a=10; $this->b=20; } function add() { $sum=$this->a+$this->b; echo "Addition of a and b is:".$sum; } function __destruct() { echo "
Destruct() function is called"; } function sub() { $sub=$this->a-$this->b; echo "
sub of a and b is:".$sub; } } $object1 = new ArithmaticOperation(); $object1->add(); $object1->sub(); unset($object1); ?> 4.file