This Python program generates a grid of numbers where:
- Each row starts with a different value
- Each value in the row increases by 100
- The starting value of each row increases by 50 compared to the previous row
This pattern creates a progressive table useful for math exercises, visual patterns, or structured data generation.
# Grid settings
rows = 5
columns = 6
start = 100
print("Generated Number Grid:")
for r in range(rows):
row = []
for c in range(columns):
row.append(start + 100 * c)
print('\t'.join(map(str, row)))
start += 50
100 200 300 400 500 600
150 250 350 450 550 650
200 300 400 500 600 700
250 350 450 550 650 750
300 400 500 600 700 800
- start defines the beginning of each row
- Each row uses start + 100 * c to generate values
- After each row, start increases by 50
- map(str, row) converts numbers to strings for printing
- '\t'.join(...) formats the row with tab spacing