Skip to content

A job challenge that I did for a company in 2023 using Ruby.

Notifications You must be signed in to change notification settings

tzanarde/JobChallenge-17-08-2023

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Job Test

Given a string s consisting of small English letters, find and return the first instance of a non-repeating character in it. If there is no such character, return '_'.

Example

For s = "abacabad", the output should be solution(s) = 'c'.

There are 2 non-repeating characters in the string: 'c' and 'd'. Return c since it appears in the string first.

For s = "abacabaabacaba", the output should be solution(s) = '_'.

There are no characters in this string that do not repeat.

Another examples

'actcay' => 't' 'abcxabc' => 'x' 'zzywxx' => 'y'

A job challenge that I did for a company in 2023 using Ruby.

Created by Tiago Zanarde.

About

A job challenge that I did for a company in 2023 using Ruby.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages