srakatexas.blogg.se

How to put all words in dictionary array
How to put all words in dictionary array







how to put all words in dictionary array

CELLS (2, 1).value = x (2), in the second row first column (A2) the value will be the second array ( x(2) ) value i.e. When the loop runs for the second time i value becomes 2 i.e. CELLS(1,1).value = x(1), in the first row first column (Cell A1) the value will be the first array ( x(1)) value i.e. CELLS (I,1).value = x(i) this means for the first time i is equal to 1 i.e. When the loop is running for the first time i value will be equal to 1. I have set the value of the variable i to 1, and I have instructed the loop to run for 1 to 5 times. In the next step, I have applied FOR loops to insert assigned numbers to the array in the first column. Later I have declared one more variable called “I” this is the second type of a variable and holds the data type of integer. X(2) = 25 means the second variable should be equal to the value of 25 and so on. X(1) = 20 means the first variable should be equal to the value of 20. This means variable x will hold 5 different types of values.ĭim x(1 To 5) As Long, i As Integer End SubĪfter that, I have assigned the values to each variable. But while declaring the variable itself, I have opened the bracket and mentioned 1 to 5.

how to put all words in dictionary array

A variable name is x, and the data type is LONG. But if I want to insert 5 consecutive numbers by using the single variable, I need to use the type array variable, which can hold many variable values in a single variable name.

how to put all words in dictionary array

In the above example, x holds only one variable that’s all.









How to put all words in dictionary array