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 the difference between a session and cookies?

0 Answers  


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

0 Answers  


What is cookie and session in php?

0 Answers  


How to move uploaded files to permanent directory?

0 Answers  


Is it necessary to use closing tag in php?sometime without closing tag things work.why?

2 Answers   ShopRite,


Which function is used to read a file removing the html and php tags in it upwork?

0 Answers  


Tell me how is it possible to remove escape characters from a string?

0 Answers  


What is difference between mysqli and mysql?

0 Answers  


How do you find the length of a string in php?

0 Answers  


How to find a specific value in an array?

0 Answers  


What is an anti csrf token?

0 Answers  


Tell me what are magic methods?

0 Answers  


Categories