Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


Write a function that takes "depth" as argument and return
sum of node's data of that depth.

For instance,

(0) depth 0
/ \
(10) (20) depth 1
/ \
(40) (50) depth2

If I pass get_sum_by_depth(2) ,

it would return 90 (i.e. 40 + 50 )


No Answer is Posted For this Question
Be the First to Post Answer

Post New Answer

More PHP Interview Questions

What is composer phar?

0 Answers  


How to count a number of words in a string in php?

0 Answers  


What are the benefits of using php and mysql?

0 Answers  


Is php worth learning in 2019?

0 Answers  


What is the php function that removes the first element of the array and returns it?

0 Answers  


Does wordpress still use php?

0 Answers  


How to find the position of the first occurrence of a substring in a string?

0 Answers  


Describe session in php.

0 Answers  


What is the sign to start variables in PHP?

0 Answers  


suppose if u want to pass session value using cookies onlu.. what changes i've to made in php.ini file?

1 Answers  


client side scripting language Vs server side scripting language

7 Answers   IBM, IRT,


How many records can be stored in mysql table?

0 Answers  


Categories