How to use large integers in Visual Basic VB without BigInteger

Back to Programming Languages forum

champagnepapi     2017-02-19 23:11:40
User avatar

i want to calculate the large integer but my VB 2015 doesnt have System.Numerics

source

Module module21

'modular balbulator
'http://www.codeabbey.com/index/task_view/modular-calculator
'19/02/17

Sub main()
    Dim processed As Int64 = Console.ReadLine()
    Dim process As String
    process = Console.ReadLine()
    Do
        If process.Substring(0, 1) = "+" Then
            processed += Int64.Parse(process.Split(" ")(1))
        ElseIf process.Substring(0, 1) = "*" Then
            processed *= Int64.Parse(process.Split(" ")(1))
        End If

        process = Console.ReadLine()
    Loop Until process.Substring(0, 1) = "%"

    processed = processed Mod Int64.Parse(process.Split(" ")(1))
    Console.Write(processed)
    Console.ReadLine()
End Sub

End Module

Quandray     2017-02-20 07:15:28
User avatar

I know this isn't answering your question, but you don't need large integers to solve the Modular Calculator problem.

champagnepapi     2017-02-23 18:02:41
User avatar

doesnt matter now i used biginteger cuH

Please login and solve 5 problems to be able to post at forum