ecco ciao............
Sub main()
Dim n,t,r1,r2,n1,n2,n3,n4
Dim am(4)
Dim am1(10),am2(10),am3(10)
Dim ruote(10)
Dim ruota(10)
Dim posta(5)
Dim poste(5)
Dim poste1(5)
posta(1)=1
poste(2)=1
poste1(2)=1.5
poste1(3)=0.5
For n=7500 To EstrazioneFin
Messaggio DataEstrazione
![Thumbs down (n) (n)](https://cdn.jsdelivr.net/joypixels/assets/8.0/png/unicode/64/1f44e.png)
t=1
Do While DISAMBO(n,t,r1,n1,n2,r2,n3,n4)=True
ruota(1)=11
ruote(1)=r1
ruote(2)=r2
s1=Fuori90(n1+n2)
If n1>n4 Then
d1=n1-n4
Else
d1=n4-n1
End If
If d1=0 Then d1=90 End If
If n3>n2 Then
d2=n3-n2
Else
d2=n2-n3
End If
If d2=0 Then d2=90 End If
If n1>n3 Then
v1=Fuori90(n1-n3)
Else
v1=Fuori90(n3-n1)
End If
If v1=0 Then v1=90 End If
If n2>n4 Then
v2=Fuori90(n2-n4)
Else
v2=Fuori90(n4-n2)
End If
If v2=0 Then v2=90 End If
If d1=d2 And v1=v2 Then
Scrivi "----------------------------------------------------------"
Scrivi NomeRuota(r1)&" "&Cint(n1)&" + "&Cint(n2)&" ="&Cint(s1)&" "& NomeRuota(r2)&" "&Cint(n3)&" + "&Cint(n4)&" ="&Cint(s1)
If d1>v1 Then
A=d1-v1
Else
A=v1-d1
End If
am(1)=Fuori90(s1+A)
ImpostaGiocata 1,am,ruote,posta,9,1
z1=90-s1
If z1=0 Then z1=90 End If
am1(1)=am(1)
am1(2)=z1
ImpostaGiocata 2,am1,ruote,poste,9,2
am2(1)=am(1)
am2(2)=Vert(z1)
ImpostaGiocata 3,am2,ruote,poste,9,2
am3(1)=am(1)
am3(2)=am1(2)
am3(3)=am2(2)
ImpostaGiocata 4,am3,ruote,poste1,9,2
For x1=2 To 4
For x2=2 To 4
ImpostaInterruzioni x1,x2,2
ImpostaInterruzioni 1,x1,2
ImpostaInterruzioni x1,1,1
Next
Next
Gioca n
End If
t=t+1
Loop
Next
ScriviResoconto
End Sub
Function DISAMBO(estrazione, tentativo, byref ruota1, byref numero1, byref numero2, byref ruota2, byref numero3, byref numero4)
Dim trovati,r,rr,i,ii,j,jj
trovati=0
For r= 1 To 9
For i= 1 To 4
For j=i+1 To 5
a=Estratto (estrazione,r,i)
b=Estratto(estrazione,r,j)
c=Fuori90(a+b)
For rr=r+1 To 10
aa=Estratto(estrazione,rr,i)
bb=Estratto(estrazione,rr,j)
cc=Fuori90(aa+bb)
If c=cc And (rr=r+1 Or ((rr-r)=5)) Then
trovati=trovati+1
If trovati=tentativo Then
numero1=a
numero2=b
numero3=aa
numero4=bb
ruota1=r
ruota2=rr
DISAMBO=True
Exit Function
End If
End If
Next
Next
Next
Next
DISAMBO=False
End Function