I am trying to make a Vigenère table using PHP. My goal is to make a big array with 26 smaller arrays in it like this:
$bigarray = [['a'-'z']['b'-'a']...['y'-'x']['z'-'y']];
I'm thinking of making the first array using the range() function, append that in the big array, then use a for loop to take the first letter, place that letter at the end and make that array append in a big array x25
$letterarray = range('a','z');
array_merge($bigarray, $firstarray);
for ($idx = 0; $idx < 26; $idx++) {
$letterarray = /* Take first letter from $letterarray, put that letter in the end. */
$bigarray = /* Put the $letterarray into the $bigarray. */
I don't know if I need to use the array_splice() or array_slice() function. I also don't know how to put the small array into the big array while keeping the 'array in array' form, because array_merge() just shoves every value into one array.