Please note, this is a STATIC archive of website www.tutorialspoint.com from 11 May 2019, cach3.com does not collect or store any user information, there is no "phishing" involved.
Tutorialspoint

dosnt compiling. all the options are right (7 = 1 week)(14 2 weeks) (25=3 weeks and 4 days)

Option Strict On
Module Module1

    Sub Main()
        Dim day As Integer = CInt(Console.ReadLine())

        If day >= 7 Then
            If day Mod 7 <> 0 Then
                Console.WriteLine(day \ 7 & " weeks and " & day Mod 7 & " days")
            Else
                Console.WriteLine((day \ 7) & " weeks")
            End If
        ElseIf day < 7 Then
            Console.WriteLine(day & " days")


        End If
        Console.ReadKey()
    End Sub

End Module

Advertisements
Loading...

We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy.