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

Describe which programming language does php parallel to?

0 Answers  


How are php sessions stored?

0 Answers  


Are php session secure?

0 Answers  


How can we encrypt the username and password using PHP?

13 Answers   Avaria, HCL, TCS, Xpert,


How can we make a constant in php?

0 Answers  


Write a statement to show the joining of multiple comparisons in php?

0 Answers  


Explain Constant in Class?

0 Answers  


How to assigning a new character in a string using php?

0 Answers  


What is the difference between explode and split?

0 Answers  


I went to an php interview yesterday.I got selected there.But,They asked me to sign bond by submitting my certificates for 2 years.Is it good or bad

7 Answers  


How can we know the number of days between two given dates using PHP?

8 Answers   AZTEC, HCL, Navsoft,


How can I make a script that can be bilingual (supports english, german)?

0 Answers  


Categories