Hello everyone. I’m new programming in processing. py. I was looking for ways of printing vectors in terminal, I know that in Java mode I can make the following:
int vector[] = { 1, 2, 3, 4 };
void setup()
{
size(50,50);
for(int i=0; i<4;i++)
{
print(vector[i]);
}
}
void draw(){}
It’ll return on terminal (Java mode):
1234
But in .py mode it returns
def setup():
size(200,200)
vector = [1, 2, 3, 4]
for i in range(len(vector)):
print vector[i]
def draw():
background(255)
1
2
3
4
I need in .py mode to print like java mode
Thanks in advance