28 lines
484 B
Markdown
28 lines
484 B
Markdown
|
# First Recurring Character
|
||
|
|
||
|
Write a program that outputs the first recurring character in a string.
|
||
|
|
||
|
## Input Description
|
||
|
|
||
|
A string of alphabetical characters. Example:
|
||
|
```text
|
||
|
ABCDEBC
|
||
|
```
|
||
|
|
||
|
## Output Description
|
||
|
|
||
|
The first recurring character from the input. From the above example:
|
||
|
```text
|
||
|
B
|
||
|
```
|
||
|
|
||
|
## Note
|
||
|
|
||
|
What is exactly the definition of 'first recurring character'?
|
||
|
- It is the character that recurs first (B in the series ABBA)
|
||
|
|
||
|
## Examples
|
||
|
```text
|
||
|
ABCDEBC ➞ B
|
||
|
ABBA ➞ B
|
||
|
```
|