Computer Science > QUESTIONS & ANSWERS > arrays in java (All)
1. In the array declaration String[] word = new String[5]; what is a. the array name? b. the base type? c. the length of the array? d. the range of values an index accessing this array can have? ... e. one of the indexed variables (or elements) of this array? 2. In the array double [] score = new double [10]; what is a. the value of score.length ? b. the fi rst index of score ? c. the last index of score ? 3. What is the output of the following code? char [] letter = {'a', 'b', 'c'}; for ( int index = 0; index < letter.length; index++) System.out.print(letter[index] + ", "); 4. What is the output of the following code? double [] a = {1.1, 2.2, 3.3}; System.out.println(a[0] + " " + a[1] + " " + a[2]); a[1] = a[2]; System.out.println(a[0] + " " + a[1] + " " + a[2]); [Show More]
Last updated: 2 years ago
Preview 1 out of 23 pages
Buy this document to get the full access instantly
Instant Download Access after purchase
Buy NowInstant download
We Accept:
Can't find what you want? Try our AI powered Search
Connected school, study & course
About the document
Uploaded On
Feb 07, 2023
Number of pages
23
Written in
All
This document has been written for:
Uploaded
Feb 07, 2023
Downloads
0
Views
87
Scholarfriends.com Online Platform by Browsegrades Inc. 651N South Broad St, Middletown DE. United States.
We're available through e-mail, Twitter, and live chat.
FAQ
Questions? Leave a message!
Copyright © Scholarfriends · High quality services·