πŸ“Š PHP
Q. What will be the output?
Code:
$a = 'abc';
$b = &$a;
$b = 'xyz';
echo $a;
  • (A) abc
  • (B) xyz
  • (C) Error
  • (D) NULL
πŸ’¬ Discuss
βœ… Correct Answer: (B) xyz

Explanation: Reference assignment updates original variable.

Explanation by: Roshan
Reference assignment updates original variable.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
1
Total Visits
πŸ“½οΈ
8 d ago
Published
πŸŽ–οΈ
Roshan
Publisher
πŸ“ˆ
88%
Success Rate