Está en la página 1de 2

EJERCICIO 1 APROBACION DE NOTA

Sub Main() Dim cal As Integer cal = InputBox("digite la calificaion") If cal > 3 Then Console.WriteLine("aprobado") Else Console.WriteLine("reprobado") End If Console.ReadLine()

End Sub

EJERCICIO 2 TABLA DE MULTIPLICAR


Sub Main() Dim a, b, c As Integer a = 12 For b = 1 To 10 c = a * b Console.WriteLine("la tabla de multiplicar del nmero 12 es:" & a & "*" & b & "=" & c) Next Console.ReadLine()

End Sub

EJERCICIO 3 AREA DE UN TRIANGULO


Sub Main() Dim base As Integer Dim altura As Integer Dim area As Integer base = 10 altura = 3 area = (base * altura) / 2 Console.WriteLine("el area del triangulo es:" & area) Console.ReadLine() End Sub

EJERCICIO 4 PAGO POR DIAS LABORADOS


Sub Main() Dim DIA, VALOR, PAGO As Integer DIA = InputBox("ESCRIBA LOS DIAS LABORADOS") VALOR = 32500 PAGO = DIA * VALOR Console.WriteLine(" el valor a pagar es:" & PAGO) Console.ReadLine() End Sub End Module

EJERCICIO 5 DETERMINAR QUE NUMERO ES MAYOR O MENOR QUE. Sub Main() Dim num_1, num_2 As Integer Console.WriteLine("ESCRIBA UN NUMERO") num_1 = Console.ReadLine Console.WriteLine("ESCRIBA UN NUMERO") num_2 = Console.ReadLine If num_1 > num_2 Then Console.WriteLine("el primer numero es mayor") End If Console.ReadLine() End Sub End Module

También podría gustarte