What is the value of $a and $b after the function call?
<?php function doSomething( &$arg ) { $return = $arg; $arg += 1; return $return; } $a = 3; $b = doSomething( $a ); ?>
A.a is 3 and b is 4
B.a is 4 and b is 3
C.Both are 3
D.Both are 4
Answers
Answered by
1
by this function we can see that a is equal to 4 and b=3
Answered by
2
✔✔✔✔
⤵⤵⤵⤵⤵⤵⤵⤵⤵⤵⤵ ıllıllıllıllıllıllııllıllıllıllıllıllııllıllıllıllıllıllı
_______________________
↪ -
<?
php function doSomething( &$arg )
{ $return = $arg; $arg += 1; return $return; }
$a = 3; $b = doSomething( $a );
?>✌✌✌
B.a is 4 and b is 3✔
_______________________ ıllıllıllıllıllıllııllıllıllıllıllıllııllıllıllıllıllıllı
Answer - By Choudhary21
⤵⤵⤵⤵⤵⤵⤵⤵⤵⤵⤵ ıllıllıllıllıllıllııllıllıllıllıllıllııllıllıllıllıllıllı
_______________________
↪ -
<?
php function doSomething( &$arg )
{ $return = $arg; $arg += 1; return $return; }
$a = 3; $b = doSomething( $a );
?>✌✌✌
B.a is 4 and b is 3✔
_______________________ ıllıllıllıllıllıllııllıllıllıllıllıllııllıllıllıllıllıllı
Answer - By Choudhary21
Attachments:
Similar questions
Social Sciences,
7 months ago
Chemistry,
7 months ago
English,
7 months ago
Computer Science,
1 year ago
Computer Science,
1 year ago
Math,
1 year ago
Math,
1 year ago