1. Can we use the for loop this way?
for(;i>5;)
2. What is the use of pointers?
3. what is array of pointer?
4. What is the difference between file and database?
5. Define data structure?
Answer / ajitha m.s.
1. This method is false and the correct syntax is
for(initialisation;condition;increment/decrement)
example: for(i=0;i<n;i++)
2.pointers are used to specify address of an element
3.Array of pointers are used to point to an array of data
items with each element of the pointer array pointing to
an element of the data array.
4.A file is a collection of bytes stored together.
database is a collection of tables and each table holds
fields as well as records.
5.Data structure is a particular way of storing and
organizing data in a computer.
Is This Answer Correct ? | 2 Yes | 3 No |
If I want to initialize the array like. int a[5] = {0}; then it gives me all element 0. but if i give int a[5] = {5}; then 5 0 0 0 0 is ans. what will I do for all element 5 5 5 5 5 in a single statement???
in malloc and calloc which one is fast and why?
What are dangling pointers in c?
why to assign a pointer to null sometimes??how can a pointer we declare get assigned with a garbage value by default???
Is struct oop?
What are header files? What are their uses?
Simplify the program segment if X = B then C ← true else C ← false
How do you determine the length of a string value that was stored in a variable?
Why doesn't C have nested functions?
What are the types of c language?
two progs are given. one starts counting frm 0 to MAX and the other stars frm MAX to 0. which one executes fast.
How pointer is different from array?