πŸ“Š PHP
Q. What will be the output?
Code:
$x = '5';
$x += 3;
echo gettype($x);
  • (A) string
  • (B) integer
  • (C) float
  • (D) Error
πŸ’¬ Discuss
βœ… Correct Answer: (B) integer

Explanation: String is converted to integer during arithmetic.

Explanation by: Roshan
String is converted to integer during arithmetic.

πŸ’¬ Discussion


πŸ“Š Question Analytics

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