alright this is what I have for the main script. What Im not too sure if I'm doing it the way the instructions is telling me to do.
%Dice Game
clc %clear command
clear %clear workspace
%Initiate Counters
one_count = 0;
five_count = 0;
three_count = 0;
%Array Of Rolls
rolls = 12;
%Generates a random number between [1...6]
x=round(rand(1,rolls)*5+1)
for i = 1:12
%Generate Counts
if i==1 || i==5 %If i = 1 or i = 5 then start counter and give money back
one_count = one_count+1
five_count = five_count+1
money_won1_5=2*one_count + five_count
else if i ==3 %Else if i = 3 then start counter and give back money
three_count = three_count+1
money_won3=three_count
end
end
end
%Dice Game
clc %clear command
clear %clear workspace
%Initiate Counters
one_count = 0;
five_count = 0;
three_count = 0;
%Array Of Rolls
rolls = 12;
%Generates a random number between [1...6]
x=round(rand(1,rolls)*5+1)
for i = 1:12
%Generate Counts
if i==1 || i==5 %If i = 1 or i = 5 then start counter and give money back
one_count = one_count+1
five_count = five_count+1
money_won1_5=2*one_count + five_count
else if i ==3 %Else if i = 3 then start counter and give back money
three_count = three_count+1
money_won3=three_count
end
end
end