java中的二维数组 [英] Two dimensional arrays in java

查看:86
本文介绍了java中的二维数组的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Which two statements are true for a two-dimensional array of primitive data type?
A. It cannot contain elements of different types.
B. The length of each dimension must be the same.
C. At the declaration time, the number of elements of the array in each dimension must be specified.
D. All methods of the class object may be invoked on the two-dimensional array.





我是什么尝试过:



回答:

A和D



有人可以解释为什么D是正确的选项吗?



What I have tried:

answer:
A and D

Could anyone explain why D is the correct option?

推荐答案

因为元素的来源无关紧要:一旦你有了实例,你可以做任何事情该类允许使用它。
Because it doesn't matter where the element comes from: once you have the instance you can do anything that the class permits with it.


这篇关于java中的二维数组的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆