1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
|
char grid[] = { 'A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z' };
// Creates the first (default) line. Line 1.
char x;
int amount; // Current line's shift.
int row; // For when all 26 rows/lines are assigned a line #
int xamount; // Previous line's shift. Will be saved as a temp value, I guess?
char length; // I have this declared as well but I'm confused on what purpose it holds.
int main ()
{
do {
amount = row + xamount; // Doesn't the first line count as 0 anyways? If so, there would be no need
// to subtract 1 as the line # as already one less, right?
// The ninth line would be seen as 8??
// Apply amount/shift to current line.
// do x++
} while (x<=25);
// Display all 26 shifted rows.
return 0;
{
|