数学中国

 找回密码
 注册
搜索
热搜: 活动 交友 discuz
楼主: ysr

几个vb小程序

[复制链接]
 楼主| 发表于 2023-1-7 22:20 | 显示全部楼层
本帖最后由 ysr 于 2023-1-7 15:14 编辑

Private Function ksm6(sa As String, sb As String) As String '某数的快速幂程序
Dim a, b
a = Val(sa)
s = Val(sb)
a1 = a
ja = 2
b = Int(Log(a) / Log(3))
Do Until ja > b
a3 = a - 3 ^ ja

If a3 = 1 Then
ksm = a & "=" & 3 & "^" & ja & "+1" & "  "
ElseIf a3 = 2 Then
ksm = a & "=" & 3 & "^" & ja & "+1+1" & "  "
Else
q1 = Sqr(Val(a3))
a2 = 2
Do While InStr(Log(a3) / Log(a2), ".") > 0 And a2 < q1
a2 = a2 + 1
Loop
r1 = Log(a3) / Log(a2)
a5 = a2
a4 = a3 - Int(Sqr(a3)) ^ 2
If a4 = 1 Then
ksm = a & "=3^" & ja & "+" & a2 & "^" & Int(r1) & "+1" & "  "
ElseIf InStr(r1, ".") = 0 Then
ksm = a & "=3^" & ja & "+" & a2 & "^" & r1 & "  "

Else
q2 = Sqr(Val(a4))
a2 = 2
Do While InStr(Log(a4) / Log(a2), ".") > 0 And a2 < q2
a2 = a2 + 1
Loop
r2 = Log(a4) / Log(a2)
If Val(r2) = 1 Then
ksm = ksm
ElseIf InStr(r2, ".") = 0 Then
ksm = a & "=3^" & ja & "+" & Int(Sqr(a3)) & "^" & 2 & "+" & a2 & "^" & r2 & "  "
Else

s = s + 1
ksm = a & "=无解" & vbCrLf
End If
End If
End If

If InStr(ksm, "+") > 0 Then
ksm6 = ksm6 & ksm
Else
ksm6 = 无解
End If
ja = ja + 1
Loop

End Function
Private Function ksm5(sa As String, sb As String) As String '某数的快速幂程序
Dim a, q
a = Val(sa)
q = Val(sb)
ja1 = 2
Do While ja1 < q
For i = ja1 To Int(q) Step 1
If InStr(ksm4(Trim(a), Val(i)), "+") = 0 Then
ah = False
Exit For

Else: ah = True
js = ksm4(Trim(a), Val(i))
End If
Next

If ah = True Then
s = s + 1
m5 = m5 & a & "=无解" & vbCrLf
Else
If InStr(js, "+") = 0 Then
m5 = m5
Else
s1 = s1 + 1
m5 = m5 & js & vbCrLf
End If
End If
ja1 = ja1 + 1
Loop

If s1 > 0 Then
ksm5 = m5
Else
ksm5 = ksm5 & a & "=无解" & vbCrLf
End If
End Function
Private Function ksm4(sa As String, sb As String) As String '某数的快速幂程序
Dim a, b
a = Val(sa)
ja1 = Val(sb)
a1 = a
ja = 2
b = Int(Log(a) / Log(ja1))
Do Until ja > b
a3 = a - ja1 ^ ja

If a3 = 1 Then
ksm = a & "=" & ja1 & "^" & ja & "+1" & "  "
ElseIf a3 = 2 Then
ksm = a & "=" & ja1 & "^" & ja & "+1+1" & "  "
Else
q1 = Sqr(Val(a3))
a2 = 2
Do While InStr(Log(a3) / Log(a2), ".") > 0 And a2 < q1
a2 = a2 + 1
Loop
r1 = Log(a3) / Log(a2)
a5 = a2
a4 = a3 - Int(Sqr(a3)) ^ 2
If a4 = 1 Then
ksm = a & "=" & ja1 & "^" & ja & "+" & Int(Sqr(a3)) & "^" & 2 & "+1" & "  "
ElseIf InStr(r1, ".") = 0 Then
ksm = a & "=" & ja1 & "^" & ja & "+" & a2 & "^" & r1 & "  "

Else
q2 = Sqr(Val(a4))
a2 = 2
Do While InStr(Log(a4) / Log(a2), ".") > 0 And a2 < q2
a2 = a2 + 1
Loop
r2 = Log(a4) / Log(a2)
If InStr(r2, ".") = 0 And r2 <> 1 Then
ksm = a & "=" & ja1 & "^" & ja & "+" & Int(Sqr(a3)) & "^" & 2 & "+" & a2 & "^" & r2 & "  "
Else

s = s + 1
ksm = a & "=无解"
End If
End If
End If

If InStr(ksm, "无解") > 0 Then
ksm4 = 无解
Else
ksm4 = ksm4 & ksm
End If
ja = ja + 1
Loop

End Function
回复 支持 反对

使用道具 举报

 楼主| 发表于 2023-1-7 22:24 | 显示全部楼层
92=64+27+1=8^2+3^3+1,
95=64+27+4=8^2+3^3+2^2.
回复 支持 反对

使用道具 举报

 楼主| 发表于 2023-1-8 21:14 | 显示全部楼层
Private Sub Command1_Click()
Dim a, b
a = Val(Text1)
a1 = a
q = Val(Text2)
m = Sqr(q)
If Right(a, 1) Mod 2 = 0 Then
a = a + 1
Else
a = a
End If
s = 0
Do While a <= m
b = a + 2
c = fenjieyinzi0(Val(a))
d = fenjieyinzi0(Val(b))
If InStr(c, "*") = 0 And InStr(d, "*") = 0 Then
s = s + 1
Print a, b, a + 1
Text3 = Text3 & "/" & a + 1
Else
s = s
End If
a = a + 2
Loop
a2 = a
s1 = s
Do While a2 <= q
B1 = a2 + 2
c1 = fenjieyinzi0(Val(a2))
D1 = fenjieyinzi0(Val(B1))

If InStr(c1, "*") = 0 And InStr(D1, "*") = 0 Then
s1 = s1 + 1
Print a2, B1, a2 + 1
Text3 = Text3 & "/" & a2 + 1
Else
s1 = s1
End If
a2 = a2 + 2

Loop
Combo1 = a1 & "与" & q & "之间有" & s1 & "对孪生素数对:" & vbCrLf & Text3
s103 = Text3
s103 = Mid(s103, 1)
Dim i As Integer
Dim ak(), s105, cr(), f
Set f = CreateObject("Scripting.Dictionary")
s105 = Split(s103, "/")
   j1 = UBound(s105)
   Print j1
   For k = 1 To j1
      n1 = n1 + 1
       ReDim Preserve ak(1 To n1)
      ak(n1) = s105(n1)
    Next
    Print ak(1)
     n = 0
        For k = 1 To j1
           For i = 1 To j1
             n = n + 1
             ReDim Preserve cr(1 To n)
            m = Val(ak(k)) + Val(ak(i))
            f(m) = ""
      Next
    Next
      n = 0
      m = f.Keys
      For i = 0 To f.Count - 1
          ReDim Preserve cr(1 To i + 1)
          cr(i + 1) = m(i)
      Next
     For i = 1 To UBound(cr) - 1
        For j = i + 1 To UBound(cr)
            If cr(i) > cr(j) Then
                temp = cr(j)
                cr(j) = cr(i)
                cr(i) = temp  'c数组是排序好的
            End If
        Next j
        
       ' If i Mod 20 = 0 Then
       ' s104 = s104 & temp & "/" & vbCrLf
       ' Else
       ' s104 = s104 & temp & "/"
       ' End If
    Next i
   
      For i = 1 To UBound(cr)
        If i Mod 20 = 0 Then
          s104 = s104 & cr(i) & "/" & vbCrLf
        Else
          s104 = s104 & cr(i) & "/"
        End If
     Next
         Print temp
         MsgBox "ok"
     MsgBox s104  '显示数组
Text4 = s104
End Sub

Private Sub Command2_Click()
Text1 = ""
Text2 = ""
Text3 = ""
Text4 = ""
Combo1 = ""
Form1.Cls
End Sub
回复 支持 反对

使用道具 举报

 楼主| 发表于 2023-1-8 21:16 | 显示全部楼层
Private Function fenjieyinzi1(a As String) As String
If Len(a) < 6 Then
fenjieyinzi1 = fenjieyinzi(Trim(a))
Else
x = 3
Do While InStr(MCC(Trim(a), 2), "/") = 0 And MBJC(Trim(a), 4) >= 0

  
If b = 0 Then
fenjieyinzi1 = fenjieyinzi1 & "2"
b = 1
Else
fenjieyinzi1 = fenjieyinzi1 & "*2"
End If
a = MCC(Trim(a), 2)
k = a
  
Loop

Do While MBJC(Trim(a), "0001") > 0
Do While MBJC(Trim(x), zhengchuqy(MBBC(Trim(a)))) <= 0
Do While InStr(MCC1(Trim(a), Trim(x)), "/") = 0 And MBJC(Trim(a), MbC(Trim(x), Trim(x))) >= 0
  
If b = 0 Then
fenjieyinzi1 = fenjieyinzi1 & x
b = 1
Else
fenjieyinzi1 = fenjieyinzi1 & "*" & x
End If
a = MCC1(Trim(a), Trim(x))
Loop
  
x = MPC1(Trim(x), 2)
Loop
  
k = a
a = 1
Loop
  
If b = 1 Then
fenjieyinzi1 = fenjieyinzi1 & "*" & k
Else
fenjieyinzi1 = "这是一个质数"
End If

End If
End Function
回复 支持 反对

使用道具 举报

 楼主| 发表于 2023-1-8 22:41 | 显示全部楼层
2/3/4/5/6/7/8/9/10/11/12/13/14/15/16/17/18/19/20/21/
22/23/24/25/26/27/28/29/30/31/32/33/34/35/36/37/38/39/40/41/
42/43/44/45/46/47/48/49/50/51/52/53/54/55/56/57/58/59/60/61/
62/63/64/65/66/67/68/69/70/71/72/73/74/75/76/77/78/79/80/81/
82/83/84/85/86/87/88/89/90/91/92/93/94/95/96/97/98/99/100/101/
102/103/104/105/106/107/108/109/111/112/113/114/115/116/117/118/119/120/121/122/
123/124/125/126/127/128/129/130/131/132/133/134/135/136/137/138/139/140/141/142/
143/144/145/146/147/148/149/150/151/152/153/154/155/156/157/158/159/160/161/162/
163/164/165/166/167/168/169/170/171/172/173/174/175/176/177/178/179/180/181/182/
183/184/185/186/187/188/189/190/191/192/193/194/195/196/197/198/199/200/201/202/
203/204/205/206/207/208/209/210/211/212/213/214/215/216/217/218/219/220/221/222/
223/224/225/226/227/228/229/230/232/233/235/237/239/240/241/242/243/244/245/246/
247/248/249/250/251/252/253/254/255/256/257/258/259/260/261/262/263/264/265/266/
267/268/269/270/271/272/273/274/275/276/277/278/279/280/281/282/283/284/285/286/
287/288/289/290/291/292/293/294/295/296/297/298/299/300/301/302/303/304/305/306/
307/308/309/310/311/312/313/314/315/316/317/318/319/320/321/322/323/324/325/326/
327/328/329/330/331/332/333/334/335/336/338/339/340/341/342/343/344/345/346/347/
348/349/350/352/355/357/359/361/364/366/368/369/370/371/372/373/375/376/377/378/
379/380/381/382/383/384/385/386/387/388/389/390/391/392/393/394/395/396/397/398/
399/400/401/402/403/404/405/406/407/408/409/410/411/412/413/414/416/418/419/420/
421/422/423/425/427/428/430/432/433/435/436/439/440/441/442/443/444/445/448/451/
457/459/460/462/464/467/486/487/488/490/491/493/494/495/496/497/498/499/500/501/
502/503/504/505/506/507/508/509/510/511/512/513/514/515/517/518/519/520/521/522/
523/524/525/526/527/528/529/531/534/536/538/540/543/545/550/551/554/557/558/559/
560/563/566/575/577/582/611/612/614/615/618/619/620/621/622/623/624/627/630/636/
638/639/641/643/646/675/678/729/730/733/736/737/738/739/742/745/754/756/761/793/
854/857/972/1025/1026/1027/1028/1029/1030/1032/1033/1034/1035/1036/1037/1038/1040/1041/1042/1043/
1044/1045/1046/1048/1049/1050/1051/1052/1053/1054/1055/1056/1057/1058/1059/1060/1061/1062/1063/1064/
1065/1066/1067/1068/1069/1071/1072/1073/1074/1075/1076/1077/1078/1079/1080/1081/1082/1083/1084/1085/
1086/1087/1088/1089/1090/1091/1092/1093/1094/1096/1097/1098/1099/1100/1101/1103/1104/1105/1106/1108/
1110/1112/1113/1114/1115/1116/1117/1119/1120/1121/1122/1123/1124/1128/1129/1131/1136/1138/1140/1142/
1145/1147/1149/1150/1151/1152/1153/1154/1156/1157/1158/1159/1160/1161/1162/1164/1165/1166/1167/1168/
1169/1170/1172/1173/1174/1175/1176/1177/1178/1179/1180/1181/1182/1183/1184/1185/1186/1187/1188/1189/
1190/1192/1193/1195/1197/1199/1200/1201/1202/1203/1204/1206/1208/1209/1211/1213/1214/1216/1217/1220/
1221/1222/1224/1225/1229/1232/1238/1240/1241/1243/1245/1248/1267/1268/1269/1271/1272/1274/1275/1276/
1277/1278/1279/1280/1281/1282/1283/1284/1285/1286/1287/1288/1289/1290/1291/1292/1293/1294/1295/1296/
1298/1299/1300/1301/1302/1303/1304/1305/1306/1307/1308/1309/1310/1312/1315/1317/1319/1321/1324/1326/
1331/1332/1335/1338/1339/1340/1341/1344/1347/1356/1358/1363/1392/1393/1395/1396/1399/1400/1401/1402/
1403/1404/1405/1408/1411/1417/1419/1420/1422/1424/1427/1456/1459/1510/1511/1514/1517/1518/1519/1520/
1523/1526/1535/1537/1542/1574/1635/1638/1753/2048/2049/2050/2052/2053/2056/2057/2058/2060/2061/2064/
2065/2066/2068/2072/2073/2074/2075/2076/2077/2079/2080/2081/2082/2083/2084/2088/2089/2091/2096/2098/
2100/2102/2105/2107/2112/2113/2116/2120/2121/2128/2137/2139/2144/2173/2174/2176/2177/2180/2181/2182/
2184/2185/2188/2189/2190/2191/2192/2193/2195/2196/2197/2198/2199/2200/2201/2203/2204/2205/2206/2207/
2208/2209/2211/2212/2213/2214/2215/2216/2217/2218/2219/2220/2221/2222/2223/2224/2225/2226/2227/2228/
2229/2230/2231/2232/2234/2235/2236/2237/2238/2239/2240/2241/2242/2243/2244/2245/2246/2247/2248/2249/
2250/2251/2252/2253/2254/2255/2256/2257/2259/2260/2261/2262/2263/2264/2266/2267/2268/2269/2271/2273/
2275/2276/2277/2278/2279/2280/2282/2283/2284/2285/2286/2287/2291/2292/2294/2295/2298/2299/2300/2301/
2303/2304/2305/2307/2308/2310/2312/2313/2314/2315/2316/2317/2318/2319/2320/2321/2322/2323/2324/2325/
2327/2328/2329/2330/2331/2332/2333/2335/2336/2337/2338/2339/2340/2341/2342/2343/2344/2345/2346/2347/
2348/2349/2350/2351/2352/2353/2355/2356/2358/2360/2362/2363/2364/2365/2366/2367/2369/2371/2372/2374/
2376/2377/2379/2380/2383/2384/2385/2387/2388/2392/2395/2401/2403/2404/2406/2408/2411/2416/2419/2430/
2431/2432/2434/2435/2437/2438/2439/2440/2441/2442/2443/2444/2445/2446/2447/2448/2449/2450/2451/2452/
2453/2454/2455/2456/2457/2458/2459/2461/2462/2463/2464/2465/2466/2467/2468/2469/2470/2471/2472/2473/
2475/2478/2480/2482/2484/2487/2489/2494/2495/2498/2501/2502/2503/2504/2507/2510/2519/2521/2526/2534/
2555/2556/2558/2559/2562/2563/2564/2565/2566/2567/2568/2571/2574/2580/2582/2583/2585/2587/2590/2619/
2622/2673/2674/2677/2680/2681/2682/2683/2686/2689/2698/2700/2705/2737/2798/2801/2916/3072/3073/3076/
3080/3081/3088/3097/3099/3104/3126/3127/3128/3129/3130/3131/3133/3134/3135/3136/3137/3138/3139/3141/
3142/3143/3144/3145/3146/3147/3149/3150/3151/3152/3153/3154/3155/3156/3157/3158/3159/3160/3161/3162/
3163/3164/3165/3166/3167/3168/3169/3170/3172/3173/3174/3175/3176/3177/3178/3179/3180/3181/3182/3183/
3184/3185/3186/3187/3188/3189/3190/3191/3192/3193/3194/3195/3197/3198/3199/3200/3201/3202/3204/3205/
3206/3207/3209/3211/3212/3213/3214/3215/3216/3217/3218/3219/3220/3221/3222/3223/3224/3225/3227/3228/
3229/3230/3231/3232/3235/3236/3237/3238/3239/3240/3241/3242/3243/3244/3245/3246/3247/3248/3250/3251/
3252/3253/3254/3255/3257/3258/3259/3260/3261/3262/3263/3265/3266/3267/3268/3269/3270/3271/3273/3274/
3275/3276/3277/3278/3279/3280/3281/3282/3283/3284/3285/3286/3287/3288/3289/3290/3291/3293/3294/3296/
3298/3300/3301/3302/3303/3304/3305/3307/3309/3310/3312/3314/3315/3317/3318/3321/3322/3323/3325/3326/
3330/3333/3336/3337/3339/3340/3341/3342/3343/3344/3345/3346/3347/3348/3349/3352/3355/3361/3363/3364/
3366/3368/3369/3370/3371/3372/3373/3375/3376/3377/3378/3379/3380/3381/3382/3383/3384/3385/3386/3387/
3388/3389/3390/3391/3392/3393/3394/3395/3396/3397/3399/3400/3401/3402/3403/3404/3405/3406/3407/3408/
3409/3410/3411/3413/3416/3418/3420/3422/3425/3427/3432/3433/3436/3439/3440/3441/3442/3445/3448/3454/
3455/3457/3458/3459/3461/3462/3463/3464/3467/3470/3479/3481/3486/3493/3494/3496/3497/3500/3501/3502/
3503/3504/3505/3506/3509/3512/3518/3520/3521/3523/3525/3528/3557/3560/3579/3582/3611/3612/3615/3618/
3619/3620/3621/3624/3627/3636/3638/3643/3675/3697/3736/3739/3854/4096/4149/4150/4151/4153/4154/4157/
4158/4159/4161/4162/4165/4166/4167/4169/4173/4174/4175/4176/4177/4178/4180/4181/4182/4183/4184/4185/
4189/4190/4192/4197/4199/4201/4203/4206/4208/4213/4214/4217/4221/4222/4229/4235/4236/4238/4239/4240/
4243/4244/4245/4251/4260/4262/4267/4274/4275/4277/4278/4281/4282/4283/4285/4286/4290/4293/4299/4301/
4302/4304/4306/4309/4338/4341/4360/4363/4374/4375/4376/4378/4379/4382/4383/4384/4386/4387/4390/4391/
4392/4393/4394/4396/4398/4399/4400/4401/4402/4403/4405/4406/4407/4408/4409/4410/4414/4415/4417/4419/
4422/4424/4426/4428/4431/4433/4438/4439/4442/4446/4447/4454/4456/4463/4465/4470/4478/4499/4500/4502/
4503/4506/4507/4508/4510/4511/4515/4517/4518/4520/4524/4526/4527/4529/4531/4534/4563/4566/4617/4618/
4621/4624/4625/4626/4627/4630/4633/4635/4642/4644/4649/4681/4742/4745/4860/5173/5174/5177/5181/5182/
5189/5198/5200/5205/5237/5259/5298/5301/5312/5313/5314/5316/5317/5320/5321/5322/5324/5325/5328/5329/
5330/5332/5336/5337/5338/5339/5340/5341/5343/5344/5345/5346/5347/5348/5352/5353/5355/5360/5362/5364/
5366/5369/5371/5376/5377/5380/5384/5385/5392/5398/5399/5401/5402/5403/5406/5407/5408/5414/5416/5423/
5425/5430/5437/5438/5440/5441/5444/5445/5446/5448/5449/5453/5456/5462/5464/5465/5467/5469/5472/5501/
5504/5523/5526/5555/5556/5559/5562/5563/5564/5565/5568/5571/5580/5582/5587/5619/5641/5680/5683/5798/
6197/6250/6251/6252/6254/6255/6258/6259/6260/6262/6263/6266/6267/6268/6270/6274/6275/6276/6277/6278/
6279/6281/6282/6283/6284/6285/6286/6290/6291/6293/6298/6300/6302/6304/6307/6309/6314/6315/6318/6322/
6323/6330/6336/6337/6339/6340/6341/6344/6345/6346/6352/6361/6363/6368/6375/6376/6378/6379/6382/6383/
6384/6386/6387/6391/6394/6400/6402/6403/6405/6407/6410/6422/6439/6442/6461/6464/6493/6494/6497/6500/
6501/6502/6503/6506/6509/6518/6520/6525/6557/6561/6562/6565/6569/6570/6577/6579/6586/6588/6593/6618/
6621/6625/6686/6689/6736/6804/7274/7275/7278/7282/7283/7290/7299/7301/7306/7338/7360/7399/7402/7499/
7500/7503/7507/7508/7515/7517/7524/7526/7531/7563/7585/7624/7627/7742/8298/8437/8438/8441/8445/8446/
8453/8462/8464/8469/8501/8523/8562/8565/8680/8748/9375/9376/9379/9383/9384/9391/9400/9402/9407/9439/
9461/9500/9503/9618/9686/10399/10624/11562/12500/16385/16386/16387/16388/16389/16390/16392/16393/16394/16395/16396/
16397/16398/16400/16401/16402/16403/16404/16405/16406/16408/16409/16410/16411/16412/16413/16414/16415/16416/16417/16418/
16419/16420/16421/16422/16423/16424/16425/16426/16427/16428/16429/16431/16432/16433/16434/16435/16436/16437/16438/16439/
16440/16441/16442/16443/16444/16445/16446/16447/16448/16449/16450/16451/16452/16453/16454/16456/16457/16458/16459/16460/
16461/16463/16464/16465/16466/16468/16470/16472/16473/16474/16475/16476/16477/16479/16480/16481/16482/16483/16484/16488/
16489/16491/16496/16498/16500/16502/16505/16507/16509/16510/16511/16512/16513/16514/16516/16517/16518/16519/16520/16521/
16522/16524/16525/16526/16527/16528/16529/16530/16532/16533/16534/16535/16536/16537/16538/16539/16540/16541/16542/16543/
16544/16545/16546/16547/16548/16549/16550/16552/16553/16555/16557/16559/16560/16561/16562/16563/16564/16566/16568/16569/
16571/16573/16574/16576/16577/16580/16581/16582/16584/16585/16589/16592/16598/16600/16601/16603/16605/16608/16627/16628/
16629/16631/16632/16634/16635/16636/16637/16638/16639/16640/16641/16642/16643/16644/16645/16646/16647/16648/16649/16650/
16651/16652/16653/16654/16655/16656/16658/16659/16660/16661/16662/16663/16664/16665/16666/16667/16668/16669/16670/16672/
16675/16677/16679/16681/16684/16686/16691/16692/16695/16698/16699/16700/16701/16704/16707/16716/16718/16723/16752/16753/
16755/16756/16759/16760/16761/16762/16763/16764/16765/16768/16771/16777/16779/16780/16782/16784/16787/16816/16819/16870/
16871/16874/16877/16878/16879/16880/16883/16886/16895/16897/16902/16934/16995/16998/17113/17408/17409/17410/17412/17413/
17416/17417/17418/17420/17421/17424/17425/17426/17428/17432/17433/17434/17435/17436/17437/17439/17440/17441/17442/17443/
17444/17448/17449/17451/17456/17458/17460/17462/17465/17467/17472/17473/17476/17480/17481/17488/17497/17499/17504/17533/
17534/17536/17537/17540/17541/17542/17544/17545/17549/17552/17558/17560/17561/17563/17565/17568/17597/17600/17651/17652/
17655/17658/17659/17660/17661/17664/17667/17676/17678/17683/17715/17776/17779/17894/18432/18433/18436/18440/18441/18448/
18457/18459/18464/18496/18557/18560/18571/18572/18573/18575/18576/18579/18580/18581/18583/18584/18587/18588/18589/18591/
18595/18596/18597/18598/18599/18600/18602/18603/18604/18605/18606/18607/18611/18612/18614/18619/18621/18623/18625/18628/
18630/18635/18636/18639/18643/18644/18651/18660/18662/18667/18675/18696/18697/18699/18700/18703/18704/18705/18707/18708/
18712/18715/18721/18723/18724/18726/18728/18731/18760/18763/18814/18815/18818/18821/18822/18823/18824/18827/18830/18839/
18841/18846/18878/18939/18942/19057/19456/19509/19510/19511/19513/19514/19517/19518/19519/19521/19522/19525/19526/19527/
19529/19533/19534/19535/19536/19537/19538/19540/19541/19542/19543/19544/19545/19549/19550/19552/19557/19559/19561/19563/
19566/19568/19573/19574/19577/19581/19582/19589/19595/19596/19598/19599/19600/19603/19604/19605/19611/19620/19622/19627/
19634/19635/19637/19638/19641/19642/19643/19645/19646/19650/19653/19659/19661/19662/19664/19666/19669/19698/19701/19720/
19723/19752/19753/19756/19759/19760/19761/19762/19765/19768/19777/19779/19784/19816/19838/19877/19880/19995/20533/20534/
20537/20541/20542/20549/20558/20560/20565/20597/20619/20658/20661/20758/20759/20762/20766/20767/20774/20776/20783/20785/
20790/20822/20883/20886/21001/21557/21696/21697/21700/21704/21705/21712/21721/21723/21728/21760/21782/21821/21824/21939/
22634/22635/22638/22642/22643/22650/22659/22661/22666/22698/22720/22759/22762/22877/22945/23658/23883/24821/25759/32768/
32769/32770/32772/32773/32776/32777/32778/32780/32781/32784/32785/32786/32788/32792/32793/32794/32795/32796/32797/32799/
32800/32801/32802/32803/32804/32808/32809/32811/32816/32818/32820/32822/32825/32827/32832/32833/32836/32840/32841/32848/
32857/32859/32864/32893/32894/32896/32897/32900/32901/32902/32904/32905/32909/32912/32918/32920/32921/32923/32925/32928/
32957/32960/33011/33012/33015/33018/33019/33020/33021/33024/33027/33036/33038/33043/33075/33136/33139/33254/33792/33793/
33796/33800/33801/33808/33817/33819/33824/33856/33917/33920/34035/34816/34955/34956/34959/34963/34964/34971/34980/34982/
34987/35019/35080/35083/35198/35893/35894/35897/35901/35902/35909/35918/35920/35925/35957/35979/36018/36021/36136/36917/
37142/38080/39018/49152/49153/49156/49160/49161/49168/49177/49179/49184/49216/49277/49280/49395/50176/51339/52277/65536/
78126/78127/78128/78129/78130/78131/78133/78134/78135/78136/78137/78138/78139/78141/78142/78143/78144/78145/78146/78147/
78149/78150/78151/78152/78153/78154/78155/78156/78157/78158/78159/78160/78161/78162/78163/78164/78165/78166/78167/78168/
78169/78170/78172/78173/78174/78175/78176/78177/78178/78179/78180/78181/78182/78183/78184/78185/78186/78187/78188/78189/
78190/78191/78192/78193/78194/78195/78197/78198/78199/78200/78201/78202/78204/78205/78206/78207/78209/78211/78213/78214/
78215/78216/78217/78218/78220/78221/78222/78223/78224/78225/78229/78230/78232/78237/78239/78241/78243/78246/78248/78250/
78251/78252/78253/78254/78255/78257/78258/78259/78260/78261/78262/78263/78265/78266/78267/78268/78269/78270/78271/78273/
78274/78275/78276/78277/78278/78279/78280/78281/78282/78283/78284/78285/78286/78287/78288/78289/78290/78291/78293/78294/
78296/78298/78300/78301/78302/78303/78304/78305/78307/78309/78310/78312/78314/78315/78317/78318/78321/78322/78323/78325/
78326/78330/78333/78339/78341/78342/78344/78346/78349/78368/78369/78370/78372/78373/78375/78376/78377/78378/78379/78380/
78381/78382/78383/78384/78385/78386/78387/78388/78389/78390/78391/78392/78393/78394/78395/78396/78397/78399/78400/78401/
78402/78403/78404/78405/78406/78407/78408/78409/78410/78411/78413/78416/78418/78420/78422/78425/78427/78432/78433/78436/
78439/78440/78441/78442/78445/78448/78457/78459/78464/78493/78494/78496/78497/78500/78501/78502/78503/78504/78505/78506/
78509/78512/78518/78520/78521/78523/78525/78528/78557/78560/78611/78612/78615/78618/78619/78620/78621/78624/78627/78636/
78638/78643/78675/78736/78739/78854/79149/79150/79151/79153/79154/79157/79158/79159/79161/79162/79165/79166/79167/79169/
79173/79174/79175/79176/79177/79178/79180/79181/79182/79183/79184/79185/79189/79190/79192/79197/79199/79201/79203/79206/
79208/79213/79214/79217/79221/79222/79229/79238/79240/79245/79274/79275/79277/79278/79281/79282/79283/79285/79286/79290/
79293/79299/79301/79302/79304/79306/79309/79338/79341/79392/79393/79396/79399/79400/79401/79402/79405/79408/79417/79419/
79424/79456/79517/79520/79635/80173/80174/80177/80181/80182/80189/80198/80200/80205/80237/80298/80301/80312/80313/80314/
80316/80317/80320/80321/80322/80324/80325/80328/80329/80330/80332/80336/80337/80338/80339/80340/80341/80343/80344/80345/
80346/80347/80348/80352/80353/80355/80360/80362/80364/80366/80369/80371/80376/80377/80380/80384/80385/80392/80401/80403/
80408/80416/80437/80438/80440/80441/80444/80445/80446/80448/80449/80453/80456/80462/80464/80465/80467/80469/80472/80501/
80504/80555/80556/80559/80562/80563/80564/80565/80568/80571/80580/80582/80587/80619/80680/80683/80798/81197/81250/81251/
81252/81254/81255/81258/81259/81260/81262/81263/81266/81267/81268/81270/81274/81275/81276/81277/81278/81279/81281/81282/
81283/81284/81285/81286/81290/81291/81293/81298/81300/81302/81304/81307/81309/81314/81315/81318/81322/81323/81330/81336/
81337/81339/81340/81341/81344/81345/81346/81352/81361/81363/81368/81375/81376/81378/81379/81382/81383/81384/81386/81387/
81391/81394/81400/81402/81403/81405/81407/81410/81439/81442/81461/81464/81493/81494/81497/81500/81501/81502/81503/81506/
81509/81518/81520/81525/81557/81579/81618/81621/81736/82274/82275/82278/82282/82283/82290/82299/82301/82306/82338/82360/
82399/82402/82499/82500/82503/82507/82508/82515/82517/82524/82526/82531/82563/82624/82627/82742/83298/83437/83438/83441/
83445/83446/83453/83462/83464/83469/83501/83523/83562/83565/83680/84375/84376/84379/84383/84384/84391/84400/84402/84407/
84439/84461/84500/84503/84618/84686/85399/85624/86562/87500/94509/94510/94511/94513/94514/94517/94518/94519/94521/94522/
94525/94526/94527/94529/94533/94534/94535/94536/94537/94538/94540/94541/94542/94543/94544/94545/94549/94550/94552/94557/
94559/94561/94563/94566/94568/94573/94574/94577/94581/94582/94589/94598/94600/94605/94634/94635/94637/94638/94641/94642/
94643/94645/94646/94650/94653/94659/94661/94662/94664/94666/94669/94698/94701/94752/94753/94756/94759/94760/94761/94762/
94765/94768/94777/94779/94784/94816/94877/94880/94995/95533/95534/95537/95541/95542/95549/95558/95560/95565/95597/95658/
95661/95776/96557/96696/96697/96700/96704/96705/96712/96721/96723/96728/96760/96821/96824/96939/97634/97635/97638/97642/
97643/97650/97659/97661/97666/97698/97720/97759/97762/97877/98658/98883/99821/100759/110893/110894/110897/110901/110902/110909/
110918/110920/110925/110957/111018/111021/111136/111917/113080/114018/127277/156250/156251/156252/156254/156255/156258/156259/156260/156262/
156263/156266/156267/156268/156270/156274/156275/156276/156277/156278/156279/156281/156282/156283/156284/156285/156286/156290/156291/156293/
156298/156300/156302/156304/156307/156309/156314/156315/156318/156322/156323/156330/156339/156341/156346/156375/156376/156378/156379/156382/
156383/156384/156386/156387/156391/156394/156400/156402/156403/156405/156407/156410/156439/156442/156493/156494/156497/156500/156501/156502/
156503/156506/156509/156518/156520/156525/156557/156618/156621/156736/157274/157275/157278/157282/157283/157290/157299/157301/157306/157338/
157399/157402/157517/158298/158437/158438/158441/158445/158446/158453/158462/158464/158469/158501/158562/158565/158680/159375/159376/159379/
159383/159384/159391/159400/159402/159407/159439/159461/159500/159503/159618/160399/160624/161562/162500/172634/172635/172638/172642/172643/
172650/172659/172661/172666/172698/172759/172762/172877/173658/174821/175759/189018/234375/234376/234379/234383/234384/234391/234400/234402/
234407/234439/234500/234503/234618/235399/236562/237500/250759/312500/
回复 支持 反对

使用道具 举报

 楼主| 发表于 2023-1-8 22:45 | 显示全部楼层
Private Sub Command1_Click()
'李明波幂和猜想的验证程序
Dim a, b, s2
a = Val(Text1)
b = Val(Text2)
a1 = Val(a)
Do While a1 <= b
s2 = s2 & "/" & a1 ^ 2
s3 = s3 & "/" & a1 ^ 3
s5 = s5 & "/" & a1 ^ 5
s7 = s7 & "/" & a1 ^ 7
a1 = a1 + 1
Loop
s10 = s2 & s3 & s5 & s7
s11 = paixu(Trim(s10))
s11 = "/" & Mid(s11, 1, Len(s11) - 1)
s12 = s10 & s11
s13 = paixu(Trim(s12))
Text3 = s13


End Sub

Private Sub Command2_Click()
Text1 = ""
Text2 = ""
Text3 = ""

End Sub


回复 支持 反对

使用道具 举报

 楼主| 发表于 2023-1-8 23:00 | 显示全部楼层
2/3/4/5/6/7/8/9/10/11/12/13/14/15/16/17/18/19/20/21/
22/23/24/25/26/27/28/29/30/31/32/33/34/35/36/37/38/39/40/41/
42/43/44/45/46/47/48/49/50/51/52/53/54/55/56/57/58/59/60/61/
62/63/64/65/66/67/68/69/70/71/72/73/74/75/76/77/78/79/80/81/
82/83/84/85/86/87/88/89/90/91/92/93/94/95/96/97/98/99/100/101/
102/103/104/105/106/107/108/109/110/111/112/113/114/115/116/117/118/119/120/121/
122/123/124/125/126/127/128/129/130/131/132/133/134/135/136/137/138/139/140/141/
142/143/144/145/146/147/148/149/150/151/152/153/154/155/156/157/158/159/160/161/
162/163/164/165/166/167/168/169/170/171/172/173/174/175/176/177/178/179/180/181/
182/183/184/185/186/187/188/189/190/191/192/193/194/195/196/197/198/199/200/201/
202/203/204/205/206/207/208/209/210/211/212/213/214/215/216/217/218/219/220/221/
222/223/224/225/226/227/228/229/230/231/232/233/234/235/236/237/238/239/240/241/
242/243/244/245/246/247/248/249/250/251/252/253/254/255/256/257/258/259/260/261/
262/263/264/265/266/267/268/269/270/271/272/273/274/275/276/277/278/279/280/281/
282/283/284/285/286/287/288/289/290/291/292/293/294/295/296/297/298/299/300/301/
302/303/304/305/306/307/308/309/310/311/312/313/314/315/316/317/318/319/320/321/
322/323/324/325/326/327/328/329/330/331/332/333/334/335/336/337/338/339/340/341/
342/343/344/345/346/347/348/349/350/351/352/353/354/355/356/357/358/359/360/361/
362/363/364/365/366/367/368/369/370/371/372/373/374/375/376/377/378/379/380/381/
382/383/384/385/386/387/388/389/390/391/392/393/394/395/396/397/398/399/400/401/
402/403/404/405/406/407/408/409/410/411/412/413/414/415/416/417/418/419/420/421/
422/423/424/425/426/427/428/429/430/431/432/433/434/435/436/437/438/439/440/441/
442/443/444/445/446/447/448/449/450/451/452/453/454/455/456/457/458/459/460/461/
462/463/464/465/466/467/468/469/470/471/472/473/474/475/476/477/478/479/480/481/
482/483/484/485/486/487/488/489/490/491/492/493/494/495/496/497/498/499/500/501/
502/503/504/505/506/507/508/509/510/511/512/513/514/515/516/517/518/519/520/521/
522/523/524/525/526/527/528/529/530/531/532/533/534/535/536/537/538/539/540/541/
542/543/544/545/546/547/548/549/550/551/552/553/554/555/556/557/558/559/560/561/
562/563/564/565/566/567/568/569/570/571/572/573/574/575/576/577/578/579/580/581/
582/583/584/585/586/587/588/589/590/591/592/593/594/595/596/597/598/599/600/601/
602/603/604/605/606/607/608/609/610/611/612/613/614/615/616/617/618/619/620/621/
622/623/624/625/626/627/628/629/630/631/632/633/634/635/636/637/638/639/640/641/
642/643/644/645/646/647/648/649/650/651/652/653/654/655/656/657/658/659/660/661/
662/663/664/665/666/667/668/669/670/671/672/673/674/675/676/677/678/679/680/681/
682/683/684/685/686/687/688/689/690/691/692/693/694/695/696/697/698/699/700/701/
702/703/704/705/706/707/708/709/710/711/712/713/714/715/716/717/718/719/720/721/
722/723/724/725/726/727/728/729/730/731/732/733/734/735/736/737/738/739/740/741/
742/743/744/745/746/747/748/749/750/751/752/753/754/755/756/757/758/759/760/761/
762/763/764/765/766/767/768/769/770/771/772/773/774/775/776/777/778/779/780/781/
782/783/784/785/786/787/788/789/790/791/792/793/794/795/796/797/798/799/800/801/
802/803/804/805/806/807/808/809/810/811/812/813/814/815/816/817/818/819/820/822/
823/824/826/827/828/829/830/831/832/833/834/835/836/837/838/839/840/841/842/843/
844/845/846/847/850/851/853/854/855/856/857/859/860/861/862/863/864/865/866/867/
868/869/871/872/873/875/878/879/880/881/882/883/884/885/886/887/888/889/890/891/
892/893/895/896/898/899/900/902/903/904/905/906/907/908/909/910/911/912/913/914/
915/916/917/918/919/920/923/927/928/929/930/931/932/933/934/935/936/937/938/939/
940/942/944/945/946/947/948/951/952/953/954/955/956/957/960/961/965/966/968/969/
971/972/975/976/978/979/980/981/983/984/987/988/989/991/992/993/996/998/999/1002/
1003/1005/1006/1007/1008/1010/1011/1012/1014/1015/1016/1018/1019/1020/1023/1024/1025/1026/1027/1028/
1029/1030/1032/1033/1034/1035/1036/1037/1038/1040/1041/1042/1043/1044/1045/1046/1047/1048/1049/1050/
1051/1052/1053/1054/1055/1056/1057/1058/1059/1060/1061/1062/1063/1064/1065/1066/1067/1068/1069/1070/
1071/1072/1073/1074/1075/1076/1077/1078/1079/1080/1081/1082/1083/1084/1085/1086/1087/1088/1089/1090/
1091/1092/1093/1094/1095/1096/1097/1098/1099/1100/1101/1102/1103/1104/1105/1106/1107/1108/1109/1110/
1111/1112/1113/1114/1115/1116/1117/1118/1119/1120/1121/1122/1123/1124/1125/1126/1127/1128/1129/1130/
1131/1132/1133/1134/1135/1136/1137/1138/1140/1141/1142/1145/1146/1147/1149/1150/1151/1152/1153/1154/
1156/1157/1158/1159/1160/1161/1162/1164/1165/1166/1167/1168/1169/1170/1171/1172/1173/1174/1175/1176/
1177/1178/1179/1180/1181/1182/1183/1184/1185/1186/1187/1188/1189/1190/1192/1193/1194/1195/1196/1197/
1198/1199/1200/1201/1202/1203/1204/1205/1206/1207/1208/1209/1210/1211/1212/1213/1214/1215/1216/1217/
1220/1221/1222/1223/1224/1225/1226/1228/1229/1230/1232/1233/1234/1237/1238/1240/1241/1242/1243/1244/
1245/1247/1248/1249/1250/1252/1253/1256/1257/1258/1260/1262/1264/1265/1266/1267/1268/1269/1271/1272/
1273/1274/1275/1276/1277/1278/1279/1280/1281/1282/1283/1284/1285/1286/1287/1288/1289/1290/1291/1292/
1293/1294/1295/1296/1297/1298/1299/1300/1301/1302/1303/1304/1305/1306/1307/1308/1309/1310/1311/1312/
1313/1314/1315/1316/1317/1319/1320/1321/1323/1324/1325/1326/1328/1329/1330/1331/1332/1335/1336/1338/
1339/1340/1341/1343/1344/1347/1348/1352/1353/1356/1358/1363/1365/1366/1367/1368/1369/1371/1372/1373/
1374/1375/1376/1377/1379/1380/1381/1383/1384/1385/1387/1390/1391/1392/1393/1394/1395/1396/1397/1398/
1399/1400/1401/1402/1403/1404/1405/1407/1408/1410/1411/1412/1414/1415/1416/1417/1419/1420/1421/1422/
1424/1425/1426/1427/1428/1429/1430/1431/1432/1435/1439/1440/1441/1443/1444/1447/1448/1452/1456/1457/
1458/1459/1460/1463/1464/1465/1467/1472/1480/1481/1483/1484/1487/1488/1490/1491/1492/1493/1495/1496/
1499/1500/1501/1503/1504/1505/1508/1510/1511/1514/1515/1517/1518/1519/1520/1522/1523/1524/1526/1527/
1528/1531/1532/1535/1536/1537/1538/1540/1541/1542/1544/1545/1546/1547/1548/1549/1552/1553/1554/1556/
1559/1560/1561/1562/1563/1564/1565/1567/1568/1569/1570/1571/1572/1573/1574/1576/1577/1579/1580/1581/
1583/1584/1585/1586/1587/1588/1589/1590/1591/1592/1593/1594/1595/1597/1599/1600/1601/1604/1608/1609/
1610/1611/1612/1614/1615/1616/1617/1618/1619/1620/1621/1623/1625/1626/1627/1632/1634/1635/1636/1637/
1638/1642/1646/1647/1649/1659/1661/1662/1664/1665/1668/1669/1670/1672/1673/1674/1677/1680/1686/1688/
1689/1691/1693/1696/1697/1699/1700/1708/1710/1711/1713/1714/1718/1719/1725/1726/1728/1735/1737/1738/
1742/1746/1752/1753/1756/1759/1760/1761/1768/1774/1777/1779/1780/1783/1784/1786/1787/1788/1789/1792/
1795/1799/1801/1804/1806/1811/1815/1816/1826/1828/1835/1838/1843/1853/1877/1879/1880/1883/1887/1888/
1895/1904/1906/1907/1911/1915/1926/1928/1943/1953/1968/1995/2004/2007/2022/2048/2049/2050/2052/2053/
2056/2057/2058/2060/2061/2064/2065/2066/2068/2072/2073/2074/2075/2076/2077/2079/2080/2081/2082/2083/
2084/2085/2088/2089/2091/2092/2093/2095/2096/2097/2098/2100/2101/2102/2105/2106/2107/2109/2111/2112/
2113/2116/2120/2121/2122/2124/2128/2129/2133/2137/2139/2144/2146/2148/2161/2173/2174/2176/2177/2180/
2181/2182/2184/2185/2188/2189/2190/2191/2192/2193/2195/2196/2197/2198/2199/2200/2201/2203/2204/2205/
2206/2207/2208/2209/2211/2212/2213/2214/2215/2216/2217/2218/2219/2220/2221/2222/2223/2224/2225/2226/
2227/2228/2229/2230/2231/2232/2233/2234/2235/2236/2237/2238/2239/2240/2241/2242/2243/2244/2245/2246/
2247/2248/2249/2250/2251/2252/2253/2254/2255/2256/2257/2258/2259/2260/2261/2262/2263/2264/2265/2266/
2267/2268/2269/2270/2271/2272/2273/2275/2276/2277/2278/2279/2280/2281/2282/2283/2284/2285/2286/2287/
2288/2289/2290/2291/2292/2293/2294/2295/2296/2297/2298/2299/2300/2301/2303/2304/2305/2307/2308/2309/
2310/2312/2313/2314/2315/2316/2317/2318/2319/2320/2321/2322/2323/2324/2325/2327/2328/2329/2330/2331/
2332/2333/2334/2335/2336/2337/2338/2339/2340/2341/2342/2343/2344/2345/2346/2347/2348/2349/2350/2351/
2352/2353/2355/2356/2357/2358/2359/2360/2361/2362/2363/2364/2365/2366/2367/2368/2369/2370/2371/2372/
2373/2374/2375/2376/2377/2378/2379/2380/2383/2384/2385/2386/2387/2388/2389/2391/2392/2393/2395/2396/
2397/2399/2400/2401/2403/2404/2405/2406/2407/2408/2410/2411/2412/2413/2415/2416/2418/2419/2420/2421/
2423/2425/2427/2428/2429/2430/2431/2432/2434/2435/2436/2437/2438/2439/2440/2441/2442/2443/2444/2445/
2446/2447/2448/2449/2450/2451/2452/2453/2454/2455/2456/2457/2458/2459/2460/2461/2462/2463/2464/2465/
2466/2467/2468/2469/2470/2471/2472/2473/2474/2475/2476/2477/2478/2479/2480/2482/2483/2484/2486/2487/
2488/2489/2491/2492/2493/2494/2495/2498/2499/2501/2502/2503/2504/2506/2507/2510/2511/2515/2516/2519/
2521/2526/2528/2529/2530/2531/2532/2534/2535/2536/2537/2538/2539/2540/2542/2543/2544/2546/2547/2548/
2550/2553/2554/2555/2556/2557/2558/2559/2560/2561/2562/2563/2564/2565/2566/2567/2568/2569/2570/2571/
2573/2574/2575/2576/2577/2578/2579/2580/2582/2583/2584/2585/2587/2588/2589/2590/2591/2592/2593/2594/
2595/2596/2598/2602/2603/2604/2606/2607/2609/2610/2611/2615/2619/2620/2621/2622/2623/2624/2626/2627/
2628/2630/2634/2635/2643/2644/2646/2647/2650/2651/2653/2654/2655/2656/2658/2659/2662/2663/2664/2666/
2667/2668/2671/2673/2674/2677/2678/2680/2681/2682/2683/2685/2686/2687/2688/2689/2690/2691/2694/2695/
2698/2699/2700/2701/2703/2704/2705/2707/2708/2709/2710/2711/2712/2715/2716/2717/2719/2722/2723/2724/
2725/2726/2727/2728/2730/2731/2732/2733/2734/2735/2736/2737/2739/2740/2742/2743/2744/2746/2747/2748/
2749/2750/2751/2752/2753/2754/2755/2756/2757/2758/2760/2762/2763/2764/2767/2771/2772/2773/2774/2775/
2776/2777/2778/2779/2780/2781/2782/2783/2784/2786/2788/2789/2790/2795/2797/2798/2799/2800/2801/2803/
2805/2809/2810/2812/2822/2824/2825/2827/2828/2831/2832/2833/2835/2836/2837/2840/2843/2849/2851/2852/
2854/2856/2859/2860/2862/2863/2871/2873/2874/2876/2877/2881/2882/2888/2889/2891/2898/2900/2901/2903/
2905/2909/2915/2916/2919/2922/2923/2924/2931/2937/2940/2942/2943/2946/2947/2949/2950/2951/2952/2955/
2958/2962/2964/2967/2969/2974/2978/2979/2989/2991/2998/3001/3006/3016/3040/3042/3043/3046/3050/3051/
3058/3067/3069/3070/3072/3073/3074/3076/3078/3080/3081/3088/3089/3091/3097/3099/3104/3106/3108/3116/
3121/3126/3127/3128/3129/3130/3131/3133/3134/3135/3136/3137/3138/3139/3141/3142/3143/3144/3145/3146/
3147/3149/3150/3151/3152/3153/3154/3155/3156/3157/3158/3159/3160/3161/3162/3163/3164/3165/3166/3167/
3168/3169/3170/3171/3172/3173/3174/3175/3176/3177/3178/3179/3180/3181/3182/3183/3184/3185/3186/3187/
3188/3189/3190/3191/3192/3193/3194/3195/3196/3197/3198/3199/3200/3201/3202/3203/3204/3205/3206/3207/
3208/3209/3210/3211/3212/3213/3214/3215/3216/3217/3218/3219/3220/3221/3222/3223/3224/3225/3226/3227/
3228/3229/3230/3231/3232/3233/3234/3235/3236/3237/3238/3239/3240/3241/3242/3243/3244/3245/3246/3247/
3248/3250/3251/3252/3253/3254/3255/3256/3257/3258/3259/3260/3261/3262/3263/3264/3265/3266/3267/3268/
3269/3270/3271/3272/3273/3274/3275/3276/3277/3278/3279/3280/3281/3282/3283/3284/3285/3286/3287/3288/
3289/3290/3291/3292/3293/3294/3295/3296/3297/3298/3299/3300/3301/3302/3303/3304/3305/3306/3307/3308/
3309/3310/3311/3312/3313/3314/3315/3316/3317/3318/3321/3322/3323/3324/3325/3326/3327/3329/3330/3331/
3333/3334/3335/3336/3337/3338/3339/3340/3341/3342/3343/3344/3345/3346/3347/3348/3349/3350/3351/3352/
3353/3354/3355/3357/3358/3359/3361/3363/3364/3365/3366/3367/3368/3369/3370/3371/3372/3373/3374/3375/
3376/3377/3378/3379/3380/3381/3382/3383/3384/3385/3386/3387/3388/3389/3390/3391/3392/3393/3394/3395/
3396/3397/3398/3399/3400/3401/3402/3403/3404/3405/3406/3407/3408/3409/3410/3411/3412/3413/3414/3415/
3416/3417/3418/3420/3421/3422/3424/3425/3426/3427/3428/3429/3430/3431/3432/3433/3435/3436/3437/3439/
3440/3441/3442/3443/3444/3445/3448/3449/3452/3453/3454/3455/3457/3458/3459/3461/3462/3463/3464/3466/
3467/3468/3469/3470/3472/3473/3474/3475/3476/3477/3478/3479/3480/3481/3482/3484/3485/3486/3488/3490/
3491/3492/3493/3494/3495/3496/3497/3498/3499/3500/3501/3502/3503/3504/3505/3506/3508/3509/3511/3512/
3513/3515/3516/3517/3518/3520/3521/3522/3523/3525/3526/3527/3528/3529/3530/3531/3532/3533/3536/3540/
3541/3542/3544/3545/3548/3549/3552/3553/3554/3555/3557/3558/3559/3560/3561/3562/3563/3564/3565/3566/
3568/3570/3573/3579/3581/3582/3584/3585/3586/3588/3589/3590/3591/3592/3593/3594/3596/3597/3600/3601/
3602/3603/3604/3605/3606/3609/3611/3612/3615/3616/3618/3619/3620/3621/3623/3624/3625/3627/3628/3629/
回复 支持 反对

使用道具 举报

 楼主| 发表于 2023-1-8 23:53 | 显示全部楼层
2/5/8/9/10/12/13/16/17/18/20/24/25/26/28/29/31/32/33/34/
35/36/40/41/43/48/50/52/54/57/59/64/65/68/72/73/80/89/91/96/
126/128/129/132/133/134/136/137/141/144/150/152/153/155/157/160/189/192/244/247/
250/251/252/253/256/259/268/270/275/307/368/371/486/1025/1028/1032/1033/1040/1049/1051/
1056/1088/1149/1152/1267/2048/2188/2191/2195/2196/2203/2212/2214/2219/2251/2312/2315/2430/3126/3129/
3133/3134/3141/3150/3152/3157/3189/3211/3250/3253/3368/4149/4374/5312/6250/16385/16388/16392/16393/16400/
16409/16411/16416/16448/16509/16512/16627/17408/18571/19509/32768/78126/78129/78133/78134/78141/78150/78152/78157/78189/
78250/78253/78368/79149/80312/81250/94509/156250/
回复 支持 反对

使用道具 举报

 楼主| 发表于 2023-1-9 00:08 | 显示全部楼层
本帖最后由 ysr 于 2023-1-8 16:19 编辑

输入1~5,输出:
/1/2/3/4/5/6/8/9/10/11/12/13/14/16/17/18/19/20/21/
22/24/25/26/27/28/29/30/31/32/33/34/35/36/37/38/39/40/41/42/
43/44/45/47/48/49/50/51/52/53/54/55/56/57/58/59/60/61/63/64/
65/66/68/69/72/73/74/76/77/80/81/82/84/88/89/90/91/92/93/95/
96/97/98/125/126/127/128/129/130/132/133/134/135/136/137/138/140/141/142/143/
144/145/146/148/149/150/151/152/153/154/155/156/157/158/159/160/161/162/189/192/
243/244/245/247/248/250/251/252/253/255/256/259/260/261/263/267/268/269/270/271/
272/274/275/276/277/307/368/371/486/1024/1025/1026/1028/1029/1032/1033/1034/1036/1037/1040/
1041/1042/1044/1048/1049/1050/1051/1052/1053/1055/1056/1057/1058/1088/1149/1152/1267/2048/2187/2188/
2189/2191/2192/2195/2196/2197/2199/2200/2203/2204/2205/2207/2211/2212/2213/2214/2215/2216/2218/2219/
2220/2221/2251/2312/2315/2430/3125/3126/3127/3129/3130/3133/3134/3135/3137/3138/3141/3142/3143/3145/
3149/3150/3151/3152/3153/3154/3156/3157/3158/3159/3189/3211/3250/3253/3368/4149/4374/5312/6250/16384/
16385/16386/16388/16389/16392/16393/16394/16396/16397/16400/16401/16402/16404/16408/16409/16410/16411/16412/16413/16415/
16416/16417/16418/16448/16509/16512/16627/17408/18571/19509/32768/78125/78126/78127/78129/78130/78133/78134/78135/78137/
78138/78141/78142/78143/78145/78149/78150/78151/78152/78153/78154/78156/78157/78158/78159/78189/78250/78253/78368/79149/
80312/81250/94509/156250/
回复 支持 反对

使用道具 举报

 楼主| 发表于 2023-1-9 00:18 | 显示全部楼层
本帖最后由 ysr 于 2023-1-10 10:50 编辑

Private Function paixu(a As String) As String
Dim i As Integer
Dim ak(), s105, cr(), f
s103 = a
Set f = CreateObject("Scripting.Dictionary")
s105 = Split(s103, "/")
   j1 = UBound(s105)
   Print j1
   For k = 1 To j1
      n1 = n1 + 1
       ReDim Preserve ak(1 To n1)
      ak(n1) = s105(n1)
    Next
    Print ak(1)
     n = 0
        For k = 1 To j1
           For i = 1 To j1
             n = n + 1
             ReDim Preserve cr(1 To n)
            m = Val(ak(k)) + Val(ak(i))
            f(m) = ""
      Next
    Next
      n = 0
      m = f.Keys
      For i = 0 To f.Count - 1
          ReDim Preserve cr(1 To i + 1)
          cr(i + 1) = m(i)
      Next
     For i = 1 To UBound(cr) - 1
        For j = i + 1 To UBound(cr)
            If cr(i) > cr(j) Then
                temp = cr(j)
                cr(j) = cr(i)
                cr(i) = temp  'c数组是排序好的
            End If
        Next j
        
       ' If i Mod 20 = 0 Then
       ' s104 = s104 & temp & "/" & vbCrLf
       ' Else
       ' s104 = s104 & temp & "/"
       ' End If
    Next i
   
      For i = 1 To UBound(cr)
        If i Mod 20 = 0 Then
          s104 = s104 & cr(i) & "/" & vbCrLf
        Else
          s104 = s104 & cr(i) & "/"
        End If
     Next
         Print temp
         MsgBox "ok"
     MsgBox s104  '显示数组
     paixu = s104
End Function
Private Function paixu1(a As String) As String
Dim i As Integer
Dim ak(), s105, cr(), f
s103 = a
Set f = CreateObject("Scripting.Dictionary")
s105 = Split(s103, "/")
   j1 = UBound(s105)
   Print j1
   For k = 1 To j1
      n1 = n1 + 1
       ReDim Preserve ak(1 To n1)
      ak(n1) = s105(n1)
    Next
    Print ak(1)
     
        For k = 1 To j1
           
             ReDim Preserve cr(1 To k)
            m = Val(ak(k))
            f(m) = ""
      Next
   
      n = 0
      m = f.Keys
      For i = 0 To f.Count - 1
          ReDim Preserve cr(1 To i + 1)
          cr(i + 1) = m(i)
      Next
     For i = 1 To UBound(cr) - 1
        For j = i + 1 To UBound(cr)
            If cr(i) > cr(j) Then
                temp = cr(j)
                cr(j) = cr(i)
                cr(i) = temp  'c数组是排序好的
            End If
        Next j
        
       ' If i Mod 20 = 0 Then
       ' s104 = s104 & temp & "/" & vbCrLf
       ' Else
       ' s104 = s104 & temp & "/"
       ' End If
    Next i
   
      For i = 1 To UBound(cr)
        If i Mod 20 = 0 Then
          s104 = s104 & cr(i) & "/" & vbCrLf
        Else
          s104 = s104 & cr(i) & "/"
        End If
     Next
         Print temp
         MsgBox "ok"
     MsgBox s104  '显示数组
     paixu1 = s104
End Function


Private Function paixu0(a As String, B As String) As String
Dim i As Integer
Dim ak(), s105, cr(), f, bk()
s103 = a
Set f = CreateObject("Scripting.Dictionary")
s105 = Split(s103, "/")
s205 = Split(B, "/")
   j1 = UBound(s105)
   j2 = UBound(s205)
   Print j1
   For k = 1 To j1
      n1 = n1 + 1
       ReDim Preserve ak(1 To n1)
      ak(n1) = s105(n1)
    Next
    For k = 1 To j2
      n2 = n2 + 1
        ReDim Preserve bk(1 To n2)
       bk(n2) = s205(n2)
    Next
    Print ak(1)
     n = 0
        For k = 1 To j1
           For i = 1 To j2
             n = n + 1
             ReDim Preserve cr(1 To n)
            m = Val(ak(k)) + Val(bk(i))
            f(m) = ""
      Next
    Next
      n = 0
      m = f.Keys
      For i = 0 To f.Count - 1
          ReDim Preserve cr(1 To i + 1)
          cr(i + 1) = m(i)
      Next
     For i = 1 To UBound(cr) - 1
        For j = i + 1 To UBound(cr)
            If cr(i) > cr(j) Then
                temp = cr(j)
                cr(j) = cr(i)
                cr(i) = temp  'c数组是排序好的
            End If
        Next j
        
       ' If i Mod 20 = 0 Then
       ' s104 = s104 & temp & "/" & vbCrLf
       ' Else
       ' s104 = s104 & temp & "/"
       ' End If
    Next i
   
      For i = 1 To UBound(cr)
        If i Mod 20 = 0 Then
          s104 = s104 & cr(i) & "/" & vbCrLf
        Else
          s104 = s104 & cr(i) & "/"
        End If
     Next
         Print temp
         MsgBox "ok"
     MsgBox s104  '显示数组
     paixu0 = s104
End Function

Private Function fenjieyinzi(sa As String) As String
Dim X, a, B
X = sa
B = Int(Sqr(Val(X)) / 2)
If X = 3 Or X = 2 Then
a = True
Else
If Right(X, 1) Mod 2 = 0 Then
a = False
Else

For i = 3 To 2 * B + 1 Step 2
If InStr(X / i, ".") = 0 Then
a = False
Exit For

Else: a = True

End If
Next
End If
End If
If a = True Then
fenjieyinzi = "这是个素数"
Else
fenjieyinzi = "2*2"
End If

End Function

Private Sub Command1_Click()
'李明波幂和猜想的验证程序
Dim a, B, s2
a = Val(Text1)
B = Val(Text2)
a1 = Val(a)
ja1 = 2
Do While a1 <= B And a1 ^ ja1 < 2000

s2 = s2 & "/" & a1 ^ 2

s3 = s3 & "/" & a1 ^ 3

s5 = s5 & "/" & a1 ^ 5

s6 = s6 & "/" & a1 ^ 7
s7 = s7 & "/" & a1 ^ 11

Do While ja2 < B And InStr(fenjieyinzi(Val(ja2)), "*") > 0
ja2 = ja2 + 1
Loop
ja1 = ja2
a1 = a1 + 1
Loop
s10 = s2 & s3 & s5 & s6 & s7 & s8 & s9
s11 = paixu(Trim(s10))
s11 = "/" & Mid(s11, 1, Len(s11) - 1)
s12 = s10 & s11
s13 = paixu0(Trim(s10), Trim(s11))
s13 = "/" & s13
s14 = s10 & s11 & s13
s15 = paixu1(Trim(s14))
s15 = Mid(s15, 2)
Text3 = s11
Combo1 = "输入:" & a & "~" & B & "输出:" & vbCrLf & s15


End Sub

Private Sub Command2_Click()
Text1 = ""
Text2 = ""
Text3 = ""
Combo1 = ""
End Sub
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

Archiver|手机版|小黑屋|数学中国 ( 京ICP备05040119号 )

GMT+8, 2024-6-15 06:03 , Processed in 0.125000 second(s), 15 queries .

Powered by Discuz! X3.4

Copyright © 2001-2020, Tencent Cloud.

快速回复 返回顶部 返回列表