Programming Languages Interview Questions
Questions Answers Views Company eMail

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 )

Amazon,

1575

Binary tree question - Node has numeric data (int) The function takes depth as argument and sum all the value of the node of the depth. For instance, (0) depth 0 / \ 10 20 depth 1 / \ / \ 40 50 60 70 depth 2 so if you pass get_sum(2), you would return 220 which is 40+50+60+70 (sum of depth2) write the function.

Amazon, FGD,

1508

Difference between data structure and data base.

CTS, Value Labs, Zoho,

7 31904

what is the difference between ph4 and php5

2 6814

What is the purpose of element of in Ajax

2013

Can we remove an element in a single linked list without traversing? Lets suppose the link list is like this 1 2 3 4 5 6 We need to remove 4 from this list (without traversing from beginning) and the final link list shud be 1 2 3 5 6 only thing we know is the pointer to element "4". How can we remove "4" and link "3" to "5"?

CSC,

6 6995

There is a number and when the last digit is moved to its first position the resultant number will be 50% higher than the original number.Find the number?

1 2609

Under what conditions is multiple inheritance not recommended?

1 4247

diff between pointer and reference in c++?

1 4293

Is there any book to know about Basics of C Language?

4 4121

How size of a class can be calulated?

2 3925

What is the difference between CV and Resume ?

2 4288

what are the stages of compilation

Bosch,

1 5794

What is optimization in c++? when using volatile.optimization is not possible..what does this mean?

1 3300

how is returning structurs from functions?Show an eg?

GE,

1 3450


Un-Answered Questions { Programming Languages }

What is the difference between echo print print_r and var_dump?

412


In an customer exit (include Z) program, only the last record is getting fetched. The exit is getting called after pressing save button. What to write for fetching the first record ? Before saved to a SAP table how can i call all these records in an itab in the exit ?

1513


What is Primary Constructor? What is Secondary or Auxiliary Constructor in Scala?

7


How to Log in to the remote datamodule?

1537


How long does a php session last for?

565






How to Get the longfilename from a file?

1240


Does the 644 permissions on wp-config.php compromise the username and password to all other users on my shared server?

96


The statement, int(*x[]) () what does in indicate?

647


How to generate a request in laravel?

399


How do I prevent my images from being hot-linked by another website?

86


Explain the Role of Publisher in Joomla?

98


What are the different import functions in r?

64


What is the use of com component in .net?

591


How do I edit my homepage on wordpress?

91


What is function pointer c?

586