use SAS 94 version Write a data step to create a data set th
use SAS 9.4 version
Write a data step to create a data set that has a variable named as digits. The values of the
variable must be non negative integers less than 240 and divisible by 7 and appear in the
descending order of magnitude. You are not allowed to use PROC SORT.
data:
Solution
Seven integers, x1, x2, x3, x4, x5, x6, and x7, are picked at random from the set of all integers between 10 and 110, inclusive. If each of these integers is divided by 7 and the 7 remainders are all added together, what would be the sum of the 7 remainders?
(1) The range of the remainders is 6.
(2) The seven integers are consecutive.
I\'m not sure where to begin with this question.
first step:
xi = 7*ki+ri where i=1 to 7.
sum of ri=?
(1) max-min (r1,....,r6)=6
(2) xi is such that x(i+1) = xi+1
So,
x1 = 7k1+r1
x2 = x1+1=7k1+r1+1
x3 = x2+1 = 7k1+r1+2
x7 = 7k1+r1+6.
sum of remainders = 7r1+1+2+3+4+5+6 = 7r1+21
one remainder is zero. so r1 can be solved for. hence B.
