Novità

Radicali

korokoro

Super member
Ciao a tutti , come posso fare per giocare la quartina radicale di questo script :
-----------------------------------------------------------------------------------------------------------------------------------

Sub main()
Dim nc(4),nr(3),num(1)
nes = InputBox("Quante estrazioni vuoi controllare?","Estrazioni",10)
id = InputBox("Quante estrazioni vuoi iniziare?","Estrazioni-",0)
ini = EstrazioneFin - nes
fin = EstrazioneFin - id
For es=ini To fin
Messaggio "Estrazione: " & es

For r1=1 To 12
If r1=11 Then r1=12
For p1 = 1 To 4
For p2=p1+1 To 5
a = Estratto (es,r1,p1)
b = Estratto (es,r1,p2)
If Radicale(a) And Radicale(b) And Radicale(a)=Radicale(b) Then
For r2=1 To 12
If r2=11 Then r2=12
If r1<>r2 Then
For p3=1 To 5
c = Estratto (es,r2,p3)
If (Radicale(c) And Radicale(a)=Radicale(c) Or Radicale(b)=Radicale(c)) Then
If a<>c And b<>c Then
nr(1)=a:nr(2)=b:nr(3)=c
rd=Radicale (a)
nc(1)=rd:nc(2)=CInt (rd&"0"):nc(3)= CInt(rd&rd):nc(4)=CInt (rd&9)
'Trova il radicale mancante
For j=1 To 4
h=0
For i=1 To 3
If nc(j)<>nr(i) Then h=h+1
Next
If h=3 Then num(1)=nc(j) : Exit For
Next
casi=casi+1:Scrivi String(75,"=")
Scrivi DataEstrazione(es,1)&" [ "&SiglaRuota(r1)&" - "&StringaEstratti(es,r1)&" ] [ "&_
Format2(a)&"."&format2(b)&" ] in "&(p1)&"^/"&(p2)&"^ pos."
Scrivi DataEstrazione(es,1)&" [ "&SiglaRuota(r2)&" - "&StringaEstratti(es,r2)&" ] [ "&_
Format2(c)&" ] in "&(p3)&"^ pos."
Scrivi "Nume. manc. ("& Format2 (num(1))&")",1
Scrivi
Scrivi "Numeri "& Format2 (a)&"."& Format2 (b)&"."& Format2 (c)&"."& Format2 (num(1))&"",1
Scrivi String(60,"-")&" caso n° "&(casi)
End If
End If
Next
End If
Next
End If
Next:Next:Next
Next
End Sub

-----------------------------------------------------------------------------------------------------------------------------------------------------------

Grazie Leo
 

joe

Advanced Member >PLATINUM PLUS<
Ciao Leo.

Lo script è un pò arzigogolato, dunque non si capisce bene se esso

sia effettivamente complicato a seguito della descrizione "di un metodo complicato"

oppure dalla ridondanza di condizioni ripetute ed eseguite reiteratamente.

Non potendo ... "decidere io" cosa semplificare oppure no, mi sono limitato,

ad inserire alcune delle cose che hai richiesto.

Codice:
Sub Main()
	Dim nc(4),nm
	Dim Nr(4),Ru(2),Po(2) : Po(2) = 2 : Co = 9
	nes = InputBox("Quante estrazioni vuoi controllare?","Estrazioni",10)
	'id = InputBox("Quante estrazioni vuoi iniziare?","Estrazioni-",0)
	ini = EstrazioneFin - nes
	fin = EstrazioneFin '- id
	For es = ini To fin
		Messaggio "Estrazione: " & es
		For r1 = 1 To 10
			If r1 = 11 Then r1 = 12
			For p1 = 1 To 4
				For p2 = p1 + 1 To 5
					a = Estratto(es,r1,p1)
					b = Estratto(es,r1,p2)
					If Radicale(a) And Radicale(b) And Radicale(a) = Radicale(b) Then
						For r2 = 1 To 12
							If r2 = 11 Then r2 = 12
							If r1 <> r2 Then
								For p3 = 1 To 5
									c = Estratto(es,r2,p3)
									If(Radicale(c) And Radicale(a) = Radicale(c) Or Radicale(b) = Radicale(c)) Then
										If a <> c And b <> c Then
											Nr(1) = a:Nr(2) = b:Nr(3) = c
											Ru(1) = R1 : Ru(2) = R2
											rd = Radicale(a)
											nc(1) = rd:nc(2) = CInt(rd & "0"):nc(3) = CInt(rd & rd):nc(4) = CInt(rd & 9)
											'Trova il radicale mancante
											For j = 1 To 4
												h = 0
												For i = 1 To 3
													If nc(j) <> Nr(i) Then h = h + 1
												Next
												If h = 3 Then nm = nc(j) : Exit For
											Next
											casi = casi + 1
											Scrivi String(106,"=") & FormatSpace(casi,3,True),True
											Scrivi DataEstrazione(es,1) & " [ " & SiglaRuota(r1) & " - " & StringaEstratti(es,r1) & " ] [ " & _
											Format2(a) & "." & Format2(b) & " ] in " &(p1) & "^/" &(p2) & "^ pos."
											Scrivi DataEstrazione(es,1) & " [ " & SiglaRuota(r2) & " - " & StringaEstratti(es,r2) & " ] [ " & _
											Format2(c) & String(3,".") & " ] in " &(p3) & "^ pos."
											Scrivi "Nume. manc. (" & Format2(nm) & ")",1
											Scrivi
											Scrivi "Numeri " & Format2(a) & "." & Format2(b) & "." & Format2(c) & "." & Format2(nm) & "",1
											Nr(4) = nm
											ImpostaGiocata 1,Nr,Ru,Po,Co,2
											Gioca Es,True
										End If
									End If
								Next
							End If
						Next
					End If
				Next
			Next
		Next
	Next
	ScriviResoconto
End Sub

:)
 

Ultima estrazione Lotto

  • Estrazione del lotto
    giovedì 02 maggio 2024
    Bari
    43
    35
    83
    74
    40
    Cagliari
    10
    23
    48
    01
    87
    Firenze
    71
    12
    04
    27
    01
    Genova
    83
    37
    42
    70
    78
    Milano
    28
    72
    27
    30
    07
    Napoli
    34
    42
    13
    67
    11
    Palermo
    37
    77
    19
    17
    12
    Roma
    79
    85
    90
    55
    49
    Torino
    83
    56
    46
    57
    19
    Venezia
    41
    48
    57
    12
    15
    Nazionale
    84
    70
    10
    67
    74
    Estrazione Simbolotto
    Milano
    22
    09
    04
    01
    11
Alto