【问题标题】:Setting an array as an input parameter for a method [closed]将数组设置为方法的输入参数 [关闭]
【发布时间】:2016-01-10 10:20:00
【问题描述】:

我将如何编写一个将双精度数据类型的数组作为输入的方法。我需要声明哪些变量?

【问题讨论】:

  • “我将如何编写一个将双精度数据类型的数组作为输入的方法。” -- 我建议使用键盘。 “我需要声明哪些变量?” -- 没有。

标签: java arrays methods parameters double


【解决方案1】:
public class FirstJavaClass {
    public void method(double[] input) {
        // ... do something amazing with it!
    }
}

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2013-07-25
    • 1970-01-01
    • 2011-12-16
    • 1970-01-01
    • 2012-10-07
    • 1970-01-01
    • 2016-04-28
    • 1970-01-01
    相关资源
    最近更新 更多