You are on page 1of 4

MAPAS DE K

Dim v(64) As Integer


Dim s As Integer

Private Sub C1_Click(Index As Integer)
If C1(Index).Caption = "1" Then
C1(Index).Caption = "0"
v(Index) = 0
Else
C1(Index).Caption = "1"
v(Index) = 1
End If
End Sub

Private Sub C2_Click(Index As Integer)
If C2(Index).Caption = "0" Then
C2(Index).Caption = "1"
v(Index) = 1
Else

C2(Index).Caption = "0"
v(Index) = 0
End If
End Sub

Private Sub C3_Click(Index As Integer)
If C3(Index).Caption = "1" Then
C3(Index).Caption = "0"
v(Index) = 0
Else

C3(Index).Caption = "1"
v(Index) = 1
End If
End Sub

Private Sub Combo1_Click()

If Combo1.Text = 2 Then
For i = 0 To 3
C1(i).Visible = True
Next i
For i = 0 To 7
C2(i).Visible = False
Next i
For i = 0 To 15
C3(i).Visible = False
Next i
End If

If Combo1.Text = 3 Then
For i = 0 To 3
C1(i).Visible = False
Next i
For i = 0 To 7
C2(i).Visible = True
Next i
For i = 0 To 15
C3(i).Visible = False
Next i
End If

If Combo1.Text = 4 Then
For i = 0 To 3
C1(i).Visible = False
Next i
For i = 0 To 7
C2(i).Visible = False
Next i
For i = 0 To 15
C3(i).Visible = True
Next i
End If
End Sub

Private Sub Command1_Click()
s = 0
For i = 0 To 64
s = s + 2 ^ i * v(i)
Next i
Select Case (s)
Case 0: Text1.Text = "0"
Case 1: Text1.Text = "A'B'C'"
Case 2: Text1.Text = "A'B'C"
Case 3: Text1.Text = "A'B'"
Case 4: Text1.Text = "A'BC"
Case 5: Text1.Text = "A'B'C'+A'BC"
Case 6: Text1.Text = "A'C"
Case 7: Text1.Text = "A'B'+A'C"
Case 8: Text1.Text = "A'BC'"
Case 9: Text1.Text = "A'C'"
Case 10: Text1.Text = "A'B'C+A'BC'"
Case 11: Text1.Text = "A'B'+A'C'"
Case 12: Text1.Text = "A'B"
Case 13: Text1.Text = "A'B+A'C'"
Case 14: Text1.Text = "A'B+A'C"
Case 15: Text1.Text = "A'"
Case 16: Text1.Text = "AB'C'"
Case 17: Text1.Text = "B'C'"
Case 18: Text1.Text = "A'B'C+AB'C'"
Case 19: Text1.Text = "A'B'+B'C'"
Case 20: Text1.Text = "A'BC+AB'C'"
Case 21: Text1.Text = "A'BC+B'C'"
Case 22: Text1.Text = "A'C+AB'C'"
Case 23: Text1.Text = "A'C+B'C'"
Case 24: Text1.Text = "A'BC'+AB'C'"
Case 25: Text1.Text = "A'C'+B'C'"
Case 26: Text1.Text = "A'B'C+A'BC'+AB'C'"
Case 27: Text1.Text = "A'B'+A'C'+B'C'"
Case 28: Text1.Text = "A'B+AB'C'"
Case 29: Text1.Text = "A'B+B'C'"
Case 30: Text1.Text = "A'B+A'C+AB'C'"
Case 31: Text1.Text = "A'+B'C'"
Case 32: Text1.Text = "AB'C"
Case 33: Text1.Text = "A'B'C'+AB'C"
Case 34: Text1.Text = "B'C"
Case 35: Text1.Text = "A'B'+B'C"
Case 36: Text1.Text = "A'BC+AB'C"
Case 37: Text1.Text = "A'B'C'+A'BC+AB'C"
Case 38: Text1.Text = "A'C+B'C"
Case 39: Text1.Text = "A'B'+A'C+B'C"
Case 40: Text1.Text = "A'BC'+AB'C"
Case 41: Text1.Text = "A'C'+AB'C"
Case 42: Text1.Text = "A'BC'+B'C"
Case 43: Text1.Text = "A'C'+B'C"
Case 44: Text1.Text = "A'B+AB'C"
Case 45: Text1.Text = "A'B+A'C'+AB'C"
Case 46: Text1.Text = "A'B+B'C"
Case 47: Text1.Text = "A'+B'C"
Case 48: Text1.Text = "AB'"
Case 49: Text1.Text = "AB'+B'C'"
Case 50: Text1.Text = "AB'+B'C"
Case 51: Text1.Text = "B'"
Case 52: Text1.Text = "A'BC+AB'"
Case 53: Text1.Text = "A'BC+AB'+B'C'"
Case 54: Text1.Text = "A'C+AB'"
Case 55: Text1.Text = "A'C+B'"
Case 56: Text1.Text = "A'BC'+AB'"
Case 57: Text1.Text = "A'C'+AB'"
Case 58: Text1.Text = "A'BC'+AB'+B'C"
Case 59: Text1.Text = "A'C'+B'"
Case 60: Text1.Text = "A'B+AB'"
Case 61: Text1.Text = "A'B+A'C'+AB'"
Case 62: Text1.Text = "A'B+A'C+AB'"
Case 63: Text1.Text = "A'B'"
Case 64: Text1.Text = "ABC"
Case 65: Text1.Text = "A'B'C'+ABC"
Case 66: Text1.Text = "A'B'C+ABC"
Case 67: Text1.Text = "A'B'+ABC"
Case 68: Text1.Text = "BC"
Case 69: Text1.Text = "A'B'C'+BC"
Case 70: Text1.Text = "A'C+BC"
Case 71: Text1.Text = "A'B'+BC"
Case 72: Text1.Text = "A'BC'+ABC"
Case 73: Text1.Text = "A'C'+ABC"
Case 74: Text1.Text = "A'B'C+A'BC'+ABC"
Case 75: Text1.Text = "A'B'+A'C'+ABC"
Case 76: Text1.Text = "A'B+BC"
Case 77: Text1.Text = "A'C'+BC"
Case 78: Text1.Text = "A'B+A'C+BC"
Case 79: Text1.Text = "A'+BC"
Case 80: Text1.Text = "AB'C'+ABC"
Case 81: Text1.Text = "ABC+B'C'"
Case 82: Text1.Text = "A'B'C+AB'C'+ABC"
Case 83: Text1.Text = "A'B'+ABC+B'C'"
Case 84: Text1.Text = "AB'C'+BC"
Case 85: Text1.Text = "B'C'+BC"
Case 86: Text1.Text = "A'C+AB'C'+BC"
Case 87: Text1.Text = "A'C+B'C'+BC"
Case 88: Text1.Text = "A'BC'+AB'C'+ABC"
Case 89: Text1.Text = "A'C'+ABC+B'C'"
Case 90: Text1.Text = "A'B'C+A'BC'+AB'C'+ABC"
Case 91: Text1.Text = "A'B'+A'C'+ABC+B'C'"
Case 92: Text1.Text = "A'B+AB'C'+BC"
Case 93: Text1.Text = "A'B+B'C'+BC"
Case 94: Text1.Text = "A'B+A'C+AB'C'+BC"
Case 95: Text1.Text = "A'+B'C'+BC"
Case 96: Text1.Text = "AC"
Case 97: Text1.Text = "A'B'C'+AC"
Case 98: Text1.Text = "AC+B'C"
Case 99: Text1.Text = "A'B'+AC"
Case 100: Text1.Text = "AC+BC"
Case 101: Text1.Text = "A'B'C'+AC+BC"
Case 102: Text1.Text = "C"
Case 103: Text1.Text = "A'B'+C"
Case 104: Text1.Text = "A'BC'+AC"
Case 105: Text1.Text = "A'C'+AC"
Case 106: Text1.Text = "A'BC'+AC+B'C"
Case 107: Text1.Text = "A'C'+AC+B'C"
Case 108: Text1.Text = "A'B+AC"
Case 109: Text1.Text = "A'C'+AC+BC"
Case 110: Text1.Text = "A'B+C"
Case 111: Text1.Text = "A'B+C"
Case 112: Text1.Text = "AB'+AC"
Case 113: Text1.Text = "AC+B'C'"
Case 114: Text1.Text = "AB'+AC+B'C"
Case 115: Text1.Text = "AC+B'"
Case 116: Text1.Text = "AB'+BC"
Case 117: Text1.Text = "AC+B'C'+BC"
Case 118: Text1.Text = "AB'+C"
Case 119: Text1.Text = "B'+C"
Case 120: Text1.Text = "A'BC'+AB'+AC"
Case 121: Text1.Text = "A'C'+AB'+AC"
Case 122: Text1.Text = "A'BC'+AB'+AC+B'C"
Case 123: Text1.Text = "A'C'+AC+B'"
Case 124: Text1.Text = "A'B+AB'+BC"
Case 125: Text1.Text = "A'B+AC+B'C'"
Case 126: Text1.Text = "A'B+AB'+C"
Case 127: Text1.Text = "A'+B'+C"
Case 128: Text1.Text = "ABC'"
Case 129: Text1.Text = "A'B'C'+ABC'"
Case 130: Text1.Text = "A'B'C+ABC'"
Case 131: Text1.Text = "A'B'+ABC'"
Case 132: Text1.Text = "A'BC+ABC'"
Case 133: Text1.Text = "A'B'C'+A'BC+ABC'"
Case 134: Text1.Text = "A'C+ABC'"
Case 135: Text1.Text = "A'B'+A'C+ABC'"
Case 136: Text1.Text = "BC'"
Case 137: Text1.Text = "A'C'+BC'"
Case 138: Text1.Text = "A'B'C+BC'"
Case 139: Text1.Text = "A'B'+BC'"
Case 140: Text1.Text = "A'B+BC'"
Case 141: Text1.Text = "A'B+A'C'+BC'"
Case 142: Text1.Text = "A'C+BC'"
Case 143: Text1.Text = "A'+BC'"
Case 144: Text1.Text = "A'+BC'"
Case 145: Text1.Text = "AC'+B'C'"
Case 146: Text1.Text = "A'B'C+AC'"
Case 147: Text1.Text = "A'B'AC'"
Case 148: Text1.Text = "A'BC+AC'"
Case 149: Text1.Text = "A'BC+AC'+B'C'"
Case 150: Text1.Text = "A'C+AC'"
Case 151: Text1.Text = "A'B'+A'C+AC'"
Case 152: Text1.Text = "AC'+BC'"
Case 153: Text1.Text = "C'"
Case 154: Text1.Text = "A'B'C+AC'+BC'"
Case 155: Text1.Text = "A'B'+C'"
Case 156: Text1.Text = "A'B+AC'"
Case 157: Text1.Text = "A'B+C'"
Case 158: Text1.Text = "A'B+A'C+AC'"
Case 159: Text1.Text = "A'+C'"
Case 160: Text1.Text = "AB'C+ABC'"
Case 161: Text1.Text = "A'B'C'+AB'C+ABC'"
Case 162: Text1.Text = "ABC'+B'C"
Case 163: Text1.Text = "A'B'+ABC'+B'C"
Case 164: Text1.Text = "A'BC+AB'C+ABC'"
Case 165: Text1.Text = "A'B'C'+A'BC+AB'C+ABC'"
Case 166: Text1.Text = "A'C+ABC'+B'C"
Case 167: Text1.Text = "A'B'+A'C+ABC'+B'C"
Case 168: Text1.Text = "AB'C+BC'"
Case 169: Text1.Text = "A'C'+AB'C+BC'"
Case 170: Text1.Text = "B'C+BC'"
Case 171: Text1.Text = "A'B'+B'C+BC'"
Case 172: Text1.Text = "A'B+AB'C+BC'"
Case 173: Text1.Text = "A'B+A'C'+AB'C+BC'"
Case 174: Text1.Text = "A'C+B'C+BC'"
Case 175: Text1.Text = "A'+B'C+BC'"
Case 176: Text1.Text = "AB'+AC'"
Case 177: Text1.Text = "AB'+AC'+B'C'"
Case 178: Text1.Text = "AC'+B'C"
Case 179: Text1.Text = "AC'+B'"
Case 180: Text1.Text = "A'BC+AB'+AC'"
Case 181: Text1.Text = "A'BC+AB'+AC'+B'C'"
Case 182: Text1.Text = "A'C+AC'+B'C"
Case 183: Text1.Text = "A'C+AC'+B'"
Case 184: Text1.Text = "AB'+BC'"
Case 185: Text1.Text = "AB'+C'"
Case 186: Text1.Text = "AB'+B'C+BC'"
Case 187: Text1.Text = "B'+C'"
Case 188: Text1.Text = "A'B+AB'+BC'"
Case 189: Text1.Text = "A'B+AB'+C'"
Case 190: Text1.Text = "A'C+AB'+BC'"
Case 191: Text1.Text = "A'+B'+C'"
Case 192: Text1.Text = "AB"
Case 193: Text1.Text = "A'B'C'+AB"
Case 194: Text1.Text = "A'B'C+AB"
Case 195: Text1.Text = "A'B'+AB"
Case 196: Text1.Text = "AB+BC"
Case 197: Text1.Text = "A'B'C'+AB+BC"
Case 198: Text1.Text = "A'C+AB"
Case 199: Text1.Text = "A'B'+AB+BC"
Case 200: Text1.Text = "AB+BC'"
Case 201: Text1.Text = "A'C'+AB"
Case 202: Text1.Text = "A'B'C+AB+BC'"
Case 203: Text1.Text = "A'B'+AB+BC'"
Case 204: Text1.Text = "B"
Case 205: Text1.Text = "A'C'+B"
Case 206: Text1.Text = "A'C+B"
Case 207: Text1.Text = "A'+B"
Case 208: Text1.Text = "AB+AC'"
Case 209: Text1.Text = "AB+B'C'"
Case 210: Text1.Text = "A'B'C+AB+AC'"
Case 211: Text1.Text = "A'B'+AB+AC'"
Case 212: Text1.Text = "AC'+BC"
Case 213: Text1.Text = "AB+B'C'+BC"
Case 214: Text1.Text = "A'C+AC'+BC"
Case 215: Text1.Text = "A'B'+AC'+BC"
Case 216: Text1.Text = "AB+AC'+BC'"
Case 217: Text1.Text = "AB+C'"
Case 218: Text1.Text = "A'B'C+AB+AC'+BC'"
Case 219: Text1.Text = "A'B'+AB+C'"
Case 220: Text1.Text = "AC'+B"
Case 221: Text1.Text = "B+C'"
Case 222: Text1.Text = "A'C+AC'+B"
Case 223: Text1.Text = "A'+B+C'"
Case 224: Text1.Text = "AB+BC"
Case 225: Text1.Text = "A'B'C'+AB+AC"
Case 226: Text1.Text = "AB+B'C"
Case 227: Text1.Text = "A'B'+AB+AC"
Case 228: Text1.Text = "AB+AC+BC"
Case 229: Text1.Text = "A'B'C'+AB+AC+BC"
Case 230: Text1.Text = "AB+C"
Case 231: Text1.Text = "A'B'+AB+C"
Case 232: Text1.Text = "AC+BC'"
Case 233: Text1.Text = "A'C'+AB+AC"
Case 234: Text1.Text = "AC+B'C+BC'"
Case 235: Text1.Text = "A'B'+AC+BC'"
Case 236: Text1.Text = "AC+B"
Case 237: Text1.Text = "A'C'+AC+B"
Case 238: Text1.Text = "B+C"
Case 239: Text1.Text = "A'+B+C"
Case 240: Text1.Text = "A"
Case 241: Text1.Text = "A+B'C'"
Case 242: Text1.Text = "A+B'C"
Case 243: Text1.Text = "A+B'"
Case 244: Text1.Text = "A+BC"
Case 245: Text1.Text = "A+B'C'+BC"
Case 246: Text1.Text = "A+C"
Case 247: Text1.Text = "A+B'+C"
Case 248: Text1.Text = "A+BC'"
Case 249: Text1.Text = "A+C'"
Case 250: Text1.Text = "A+B'C+BC'"
Case 251: Text1.Text = "A+B'+C'"
Case 252: Text1.Text = "A+B"
Case 253: Text1.Text = "A+B+C'"
Case 254: Text1.Text = "A+B+C"
Case 255: Text1.Text = "1"
End Select
End Sub

Private Sub Command2_Click()
Select Case (s)
Case 0:
Case 1: Picture1.Picture = ("C:\Documents and
Settings\PC - 17\Escritorio\0001.jpeg")
Case 2: Picture1.Picture = ("C:\Documents and
Settings\PC - 17\Escritorio\0010.jpeg")
End Select
End Sub

Private Sub Form_Load()
Combo1.AddItem ("1")
Combo1.AddItem ("2")
Combo1.AddItem ("3")
Combo1.AddItem ("4")
End Sub

You might also like