suppose a,b,c and d are different positive integers whose sum is 100, and a-c=5. what is the greatest possible value of ab-cd?

ab - cd will be a maximum if ab is as large as possible and cd is as small as possible

I will let d = 1
also we are told that c = a -5, so it is close to a
for a maximum of ab, a = b, but our numbers are to be different, and remember that c is only 5 less than a.
So we know that a,b, and c must be close to each other, and their sum = 99

- so each one is around 33

let's make a chart
A - B - C - D -- AB-CD
35 34 30 1 ---- 1160
34 36 29 1 ---- 1195
33 38 28 1 ---- 1226
..
30 44 25 1 ---- 1296
29 46 24 1 ---- 1310
28 48 26 1 ----- 1318
27 50 22 1 ----- 1328
26 52 21 1 ----- 1331 <------ the highest
25 54 20 1 ----- 1330
24 56 19 1 ----- 1325 - lower than before

To find the greatest possible value of ab - cd, we need to maximize both ab and cd. Since a, b, c, and d are different positive integers, their range will be limited.

First, let's consider the constraint a - c = 5. Since a and c are positive integers, the minimum possible value for a is 6 (with c = 1) and the minimum possible value for c is 1 (with a = 6).

Now, let's find the maximum possible value for ab. To maximize ab, we want to choose the largest possible values for a and b. Since a must be greater than c, the maximum possible value for a is 98 (with c = 93). Conversely, the minimum possible value for b is 2 (with a = 98).

Next, let's find the maximum possible value for cd. To maximize cd, we want to choose the largest possible values for c and d. Since c must be less than a, the maximum possible value for c is 97 (with a = 98). Conversely, the minimum possible value for d is 4 (with c = 97).

Now, we can calculate the values of ab and cd:

ab = 98 * 2 = 196
cd = 97 * 4 = 388

Finally, we can find the maximum value of ab - cd:

ab - cd = 196 - 388 = -192

Therefore, the greatest possible value of ab - cd is -192.