Advertisements
Advertisements
प्रश्न
What is the need of Dimensional Array? Explain.
संक्षेप में उत्तर
उत्तर
- Assume we want to save 20 students' English marks. We will need to employ 20 different variables. Remembering the variable names becomes a difficult task. Attempting to save all 20 values in a single variable will result in the variable only holding the last assigned value.
- To prevent the problems described above, an array is required. Arrays require only one variable name with indexes, making it easier to memorize. Values will not be overwritten since each subscripted variable relates to a specific memory address.
shaalaa.com
क्या इस प्रश्न या उत्तर में कोई त्रुटि है?