首页 > 文档 > printArray()打印数组
2017
08-01

printArray()打印数组

Name

printArray()打印数组

   

Examples

float[] f = { 0.3, 0.4, 0.5 };

printArray(f);

 

// The above code prints:

// [0] 0.3

// [1] 0.4

// [2] 0.5

Description

The printArray() function writes array data to the text area of the Processing environment’s console. A new line is put between each element of the array. This function can only print one dimensional arrays.

Note that the console is relatively slow. It works well for occasional messages, but does not support high-speed, real-time output (such as at 60 frames per second).

printarray () 函数将数组数据写入处理环境的控制台的文本区域。在数组的每个元素之间放置一个新行。此函数只能打印一维数组。

 

请注意, 控制台相对较慢。它对偶尔的消息很有效, 但不支持高速、real-time 的输出 (如每秒60)

Syntax

printArray(what)

Parameters

what

Object: one-dimensional array

 

一维数组

Returns

void

Related

print()
println()



最后编辑:
作者:卡萨布兰卡
这个作者貌似有点懒,什么都没有留下。

留下一个回复

你的email不会被公开。