请写出六个不同的正整数,使任意两个数的差能整除这两个数的和

4个回答

  • 太多了 0-100范围之内就有8组

    30 35 36 40 42 45

    36 40 42 44 45 48

    56 60 63 70 72 84

    60 70 72 75 80 90

    60 70 72 80 84 90

    72 75 78 80 81 90

    72 78 80 81 84 90

    72 80 84 88 90 96

    .

    我编程计算的,用的是vb,源程序是

    Private Sub Command1_Click()

    For i = 1 To 100

    X1 = i

    For j = i + 1 To 100

    X2 = j

    If (i + j) Mod (j - i) = 0 Then

    For k = j + 1 To 100

    x3 = k

    If (x3 + X1) Mod (x3 - X1) = 0 Then

    If (x3 + X2) Mod (x3 - X2) = 0 Then

    For l = k + 1 To 100

    x4 = l

    If (x4 + X1) Mod (x4 - X1) = 0 Then

    If (x4 + X2) Mod (x4 - X2) = 0 Then

    If (x4 + x3) Mod (x4 - x3) = 0 Then

    For m = l + 1 To 100

    x5 = m

    If (x5 + X1) Mod (x5 - X1) = 0 Then

    If (x5 + X2) Mod (x5 - X2) = 0 Then

    If (x5 + x3) Mod (x5 - x3) = 0 Then

    If (x5 + x4) Mod (x5 - x4) = 0 Then

    For n = m + 1 To 100

    x6 = n

    If (x6 + X1) Mod (x6 - X1) = 0 Then

    If (x6 + X2) Mod (x6 - X2) = 0 Then

    If (x6 + x3) Mod (x6 - x3) = 0 Then

    If (x6 + x4) Mod (x6 - x4) = 0 Then

    If (x6 + x5) Mod (x6 - x5) = 0 Then

    Print X1,X2,x3,x4,x5,x6

    f = f + 1

    If f = 10 Then

    i = 1001

    j = 1001

    k = 1001

    l = 1001

    End If

    End If

    End If

    End If

    End If

    End If

    Next n

    End If

    End If

    End If

    End If

    Next m

    End If

    End If

    End If

    Next l

    End If

    End If

    Next k

    End If

    Next j

    Next i

    End Sub

    因为实在太多了,所以我只让显示0-100范围之内的