Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
check with hashset
'Title of this code 'Rextester.Program.Main is the entry point for your code. Don't change it. 'Compiler version 11.0.50709.17929 for Microsoft (R) .NET Framework 4.5 Imports System Imports System.Collections.Generic Imports System.Linq Imports System.Text.RegularExpressions Namespace Rextester Public Module Program function check(a as string, b as string) dim b_uniq as HashSet(Of Char) = new HashSet(Of char)(b) For Each c as char in a if not b_uniq.Contains(c) then return False next return True end function Public Sub Main(args() As string) Console.WriteLine(check("urok", "kkkonkurs")) Console.WriteLine(check("konkurs", "surokn")) End Sub End Module End Namespace
run
|
edit
|
history
|
help
0
pgcd def
Selected Poems of Rumi Dover Thrift Edition...day#doy~Poem#n
exercicio A
Declaração de Variaveis
Web application
ok
ss
png
CD.SYS
VB checking whether a date is between 2 dates