Tutor profile: Aniruddha B.
Subject: Information Technology
When to use Array Lists and Linked Lists?
Array Lists are static data structures. The access time is constant, that is O(1). Due to fast access time, Array Lists can be used in applications where data is accessed frequently. Linked Lists on the other hand are dynamic in nature. The memory size that the linked list takes can be allocated or deallocated when inserting or deleting data. That means you can update the linked lists by making efficient use of memory. Thus, for update operations, Linked Lists are preferred. Do note that, linked lists take O(N) time to search for an element. Thus they are not ideal for frequently data accessing applications.
Subject: Computer Science (General)
What is primary and secondary memory?
Primary memory as obvious from its name is the main memory of the computer which is accessed by the CPU. We generally call it RAM (Random Access Memory). It is a volatile memory yet high-speed memory and stores information regarding the programs currently running on your computer. Secondary memory is used to store data as well as program information permanently. It is a non-volatile memory which means the contents stored on it are permanent. But compared to primary memory, the secondary memory in slow in terms of speed.
Subject: C++ Programming
What is the difference between #include<filename> and #include "filename"?
The difference is only in the location where the preprocessor searches for the specified file. 1) In #include <filename> the preprocessor searches standard folders and directories to access the file. This notation is generally used to include standard C++ libraries and files. 2) In #include "filename" the preprocessor firsts searches for the file in the same folder which contains the source file of the code. Then it searches in the locations as it does for #include <filename> notation.
needs and Aniruddha will reply soon.