Difference between revisions of "ZCubes/Understanding Arrays in ZCubes"

From ZCubes Wiki
Jump to navigation Jump to search
(Created page with "==Understanding Arrays in ZCubes== <br/> This video demonstrates some of the array creation and manipulation features in ZCubes. A series of numbers can be made into an array...")
 
 
(One intermediate revision by one other user not shown)
Line 8: Line 8:
 
<br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/>
 
<br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/><br/>
  
 +
==Code==
 +
a=(1..100);
 +
b=a.parts(10);
 +
b=a.slice(1,10);
 +
b=a.slice(50,66);
 +
b=a.parts(10)
 +
SUM(b);
 +
b.$(SIN);
 +
b.$(x=>x^2);
 +
b.$$(SUM);
 +
b.$$$(SUM);
 +
b.columns();
 +
b.columns(3);
 +
b.columns(1..3);
 +
b.columns(0..9..2);
 +
b.rows(0..9..2);
  
 
<<[[Learn_ZCubes | Learn ZCubes ]]
 
 
<br/>
 
<br/>
&copy; Copyright 1996-2020, ZCubes, Inc.
+
*[[Z3 | Z3 home]]
 +
*[[Z^3 Language Documentation]]
 +
*[[ZCubes_Videos | ZCubes Videos and Tutorials]]
 +
*[[Main_Page | About ZCubes ]]
 +
<br/>
 +
<br/>
 +
&copy; Copyright 1996-2021, ZCubes, Inc.

Latest revision as of 00:29, 11 March 2021

Understanding Arrays in ZCubes


This video demonstrates some of the array creation and manipulation features in ZCubes. A series of numbers can be made into an array and you can use functions to obtain and manipulate data in rows, columns or cells. This also demonstrates the use of the ".." operator. Go ahead and play with arrays.

Video


Understanding Arrays in ZCubes














Code

a=(1..100);
b=a.parts(10);
b=a.slice(1,10);
b=a.slice(50,66);
b=a.parts(10)
SUM(b);
b.$(SIN);
b.$(x=>x^2);
b.$$(SUM);
b.$$$(SUM);
b.columns();
b.columns(3);
b.columns(1..3);
b.columns(0..9..2);
b.rows(0..9..2);




© Copyright 1996-2021, ZCubes, Inc.