How Do You Build A Computer Table?
You can build a computer table using the most general of programming concepts, the array and the nested loop. These concepts can be used with any programming language. The array is often used to store large amounts of information. The nested loop is basically two loops, one inside the other. Of course, you can use a spreadsheet or a database program to create a table, too. But the array and the nested loop are the general logic concepts that are often used in programming. You can build a simple table in Visual Basic using an array and two loops. Start Excel, open a new spreadsheet, and hold “Alt” and “F11” to enter the Visual Basic Editor. Select “Insert” and “Module” and click in the new module to start copying code. Type in the following code. Sub TestArray() ‘ Comments start with quote sign ‘Activate worksheet and go to cell A1 Worksheets(“Sheet1”).Activate Application.Goto Reference:=Worksheets(“Sheet1”).Range(“A1”) ‘ Setup a 2-dimensional array having 5 places in first dimension a