11.08.2013 Views

Excel's Formula - sisman

Excel's Formula - sisman

Excel's Formula - sisman

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

372<br />

Part IV: Array <strong>Formula</strong>s<br />

Understanding the Dimensions of an Array<br />

As stated previously, an array can be either one-dimensional or two-dimensional. A onedimensional<br />

array’s orientation can be either vertical or horizontal.<br />

One-dimensional horizontal arrays<br />

The elements in a one-dimensional horizontal array are separated by commas. The following<br />

example is a one-dimensional horizontal array constant:<br />

{1,2,3,4,5}<br />

To display this array in a range requires five consecutive cells in a single row. To enter this array<br />

into a range, select a range of cells that consists of one row and five columns. Then enter<br />

={1,2,3,4,5} and press Ctrl+Shift+Enter.<br />

If you enter this array into a horizontal range that consists of more than five cells, the extra cells<br />

will contain #N/A (which denotes unavailable values). If you enter this array into a vertical range<br />

of cells, only the first item (1) will appear in each cell.<br />

The following example is another horizontal array; it has seven elements and is made up of text<br />

strings:<br />

{“Sun”,”Mon”,”Tue”,”Wed”,”Thu”,”Fri”,”Sat”}<br />

To enter this array, select seven cells in one row and then type the following (followed by pressing<br />

Ctrl+Shift+Enter):<br />

={“Sun”,”Mon”,”Tue”,”Wed”,”Thu”,”Fri”,”Sat”}<br />

One-dimensional vertical arrays<br />

The elements in a one-dimensional vertical array are separated by semicolons. The following is a<br />

six-element vertical array constant:<br />

{10;20;30;40;50;60}<br />

Displaying this array in a range requires six cells in a single column. To enter this array into a<br />

range, select a range of cells that consists of six rows and one column. Then enter the following<br />

formula, and press Ctrl+Shift+Enter:<br />

={10;20;30;40;50;60}

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!