clc;                                        % clear the command window
clear all;                                  % clear all variables
close all;                                  % close all ports and plots
rng('shuffle');                             % seed the random number generator

days_running = 0;                           % a variable
days_gym = 0;                               % a variable

for day_counter = 1:7                       % a loop counter
     did_it_rain = rand(1);                 % pick a random number between 0 1nd 1
     if did_it_rain  <= 0.3                 % an if statement
          days_gym = days_gym + 1;          % add one to this variable
     else                                   % the other if option
          days_running = days_running + 1;  % add one to this variable
     end                                    % end the if loop
end                                         % end the for loop
disp(['You went to the gym ' num2str(days_gym) ' days and went running ' num2str(days_running) ' days']);                                                                                    % end the loop