%% Append Suffix to Table Variable Names
% Create a table with many variables by using the array2table function. Add names for the variables.

T = array2table(rand(5,5))

%
% Change the variable names so that they each start with "Reading" and end with a suffix. Determine how many variables T has by using the width function. Specify the table variables as a numeric array.
% Convert the numeric array allVars to a string array. Create a 1-by-5 string array by appending each element to "Reading".
% Rename all of the variables by using the renamevars function.

allVars = 1:width(T);
newNames = append("Reading",string(allVars));
T = renamevars(T,allVars,newNames)

% Copyright 2019 The MathWorks, Inc.