Permalink
Cannot retrieve contributors at this time
Fetching contributors…
| ' Visual Basic .NET Document | |
| ' | |
| Option Strict On | |
| ' <Snippet8> | |
| Imports System.Text.RegularExpressions | |
| Module Example | |
| Public Sub Main() | |
| Dim pattern As String = "\b\w+\b(?!\p{P})" | |
| Dim input As String = "Disconnected, disjointed thoughts in a sentence fragment." | |
| For Each match As Match In Regex.Matches(input, pattern) | |
| Console.WriteLine(match.Value) | |
| Next | |
| End Sub | |
| End Module | |
| ' The example displays the following output: | |
| ' disjointed | |
| ' thoughts | |
| ' in | |
| ' a | |
| ' sentence | |
| ' </Snippet8> |