Answers for "sequnce function vb.net"

0

sequnce function vb.net

Private Function SequentialNumbers(ByVal input As String) As Boolean
        Dim numbers() As Int32 = Array.ConvertAll(input.ToCharArray(), Function(c) Convert.ToInt32(c))
        For index As Int32 = 0 To numbers.Length - 2
            For nestedIndex As Int32 = index + 1 To numbers.Length - 1
                If numbers(index) = numbers(nestedIndex) - 1 Then
                    Return True
                End If
            Next
        Next

        Return False
    End Function
Posted by: Guest on December-28-2020

Code answers related to "BASIC"

Browse Popular Code Answers by Language