How can you quickly find the number of elements stored in a dynamic array? Why is it difficult to store linked list in an array?


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

Post New Answer

More C++ General Interview Questions

reading material is provided 3 books for c++ if u need more do let me know thnx i hve lots of material do let me know if u want it

2 Answers  


Can we declare destructor as static? Explain?

3 Answers  


Are iterators pointers?

0 Answers  


What is the difference between public, private, protected inheritance?

12 Answers   Wipro,


Are vectors passed by reference c++?

0 Answers  


Can c++ do everything c can?

0 Answers  


How to construct muliton object

2 Answers   Symphony, TCS,


Where and why do I have to put the "template" and "typename" keywords?

0 Answers  


can any one help to find a specific string between html tags which is changed to a sting.. weather.html looks (for location) is <location>somewhere</location> #include <iostream> #include <fstream> #include <string> using namespace std; string find_field(string myPage,string); int main (void) { string page, line, location, temperature; ifstream inputFile("weather.xml"); while(getline(inputFile, line)) { page.append(line); line.erase(); } // Now page is a string that contains the whole xml page // Here you need to write something that finds and // extracts location and temperature from the XML // data in the string page and stores them in // the strings location and temperature respectively location=find_field(page,"location"); temperature=find_field(page,"temp_c"); cout << "Location: "<<location << endl; cout << "Temperature: " << temperature << endl; system("pause"); } string find_field(string myPage,string find_string){ int temp=myPage.find(find_string); if(temp!=string::npos) { cout << "Match found at " << temp << endl; } return "found?"; } ///

0 Answers  


sir i want to study the c++ course but ino what is the qualification and the study methode please reply more details in c++

1 Answers   NIIT,


what is the basic concept of c++(object oriented programing)

4 Answers   Wipro,


Define precondition and post-condition to a member function?

1 Answers  


Categories