GridGenerator[1] is a console application software developed by Miklós Székely for demonstration purposes. It was originally written in Batch, but it has a version written in C++ and Small Basic

GridGenerator

edit
 
The logo of the software Gridgenerator

GridGenerator[1] generates a grid from the user's input for height, width and grid character (the character that makes up every unit of the grid).

The program

edit
  • It is made up by a variable (including user input variables) declaring section.
  • And the grid generator part itself is made up by for loop and another forloop nested inside it. Each for loop makes one dimension of the grid.
  • The following is GridGenerator's small basic version's code:
loop:

TextWindow.WriteLine("GridChar: ") 'Variables
GridChar = TextWindow.Read()
TextWindow.WriteLine("x: ")
x = TextWindow.Read()
TextWindow.WriteLine("y: ")
y = TextWindow.Read()

For a = 0 To y                          'Grid generation
    For b = 0 To x
        TextWindow.Write(GridChar)
    EndFor
    TextWindow.WriteLine("")
EndFor

GoTo loop

Reference section

edit
  1. ^ a b "User:Ayowhatsupp/Sample page", Wikipedia, 2022-05-28, retrieved 2022-05-30

Return to the tutorial

  1. ^ Cite error: The named reference :0 was invoked but never defined (see the help page).