मराठी

Differentiate between the following: length and length() - Computer Applications

Advertisements
Advertisements

प्रश्न

Differentiate between the following:

length and length()

Write the difference between length and length() functions.

फरक स्पष्ट करा

उत्तर

S. No. length length()
1. This method is used to determine the size of an array. The length() method is used to determine the size of a string.
2. Example: int a[] = new int[100] Example: Strings = "summer";
3. In the above example, a.length returns 100 In the above example, s.length() returns 6
shaalaa.com
  या प्रश्नात किंवा उत्तरात काही त्रुटी आहे का?
पाठ 3: Arrays (Single Dimensional and Double Dimensional) - EXERCISES [पृष्ठ २४०]

APPEARS IN

अविचल Computer Applications [English] Class 10 ICSE
पाठ 3 Arrays (Single Dimensional and Double Dimensional)
EXERCISES | Q VI. 8. | पृष्ठ २४०
अविचल Computer Applications [English] Class 10 ICSE
पाठ 3 Arrays (Single Dimensional and Double Dimensional)
Review Insight | Q 4. | पृष्ठ २३६
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×