FastPrepFirst Character Seen Only Once
Problems/First Character Seen Only Once

First Character Seen Only Once

Rippling logoRippling● EasyFULLTIMEPHONE SCREEN

Updated Nov 2026

QuestionFunctionExamplesConstraints

Problem statement

Source note: A software development engineer who received a Rippling offer wrote a review in July 2026 that the coding round asked for the earliest character in a string that occurs only once, next to a bracket-balance question. The review names the task and gives nothing else.

It does not say what to return, whether letter case matters, which characters can appear, or what happens when every character repeats. Here the answer is the character itself as a one-letter string, uppercase and lowercase letters count as different characters, the string holds only letters and digits, an empty string means every character repeats, and the limits and examples are our own.

Our version is about 85% the same as the reported question.

You are given a string s. Scan it from left to right and find the first character that occurs exactly once in the whole string.

Return that character as a string of length 1. Uppercase and lowercase letters are different characters, so 'a' and 'A' are counted separately. If every character occurs more than once, return an empty string "".

Function

firstSingleCharacter(s: String) → String

Examples

Example 1

s = "onboarding"return = "b"

Counts: o 2, n 2, b 1, a 1, r 1, d 1, i 1, g 1. Going left to right, o and n repeat, and b is the first character that appears once.

Example 2

s = "xXyx"return = "X"

Uppercase and lowercase are different characters. x appears twice, X appears once, so the answer is "X".

Example 3

s = "teammate"return = ""

Every character repeats: t, e, a and m each appear twice. The answer is "".

Constraints

  • 1 <= s.length <= 10^4
  • s consists only of English letters (uppercase and lowercase) and digits.

More Rippling Phone Screen questions

  • Filter, Sort, and Deduplicate Scheduled TasksPHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
  • Stateful Log Transform and SearchPHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
  • Dependency-Aware Task SchedulerPHONE SCREEN · Seen Nov 2026
  • Delivery Cost Tracker with Effective-Dated RatesPHONE SCREEN · Seen Nov 2026
  • Camel CardsPHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
  • Best and Worst Camel Card CompletionsPHONE SCREEN · Seen Nov 2026
  • Corporate Card Expense RulesOA · PHONE SCREEN · ONSITE INTERVIEW · Seen Oct 2026
  • In-Memory Priority Task SchedulerPHONE SCREEN · Seen Oct 2026
  • Limit an Organization Tree's HeightPHONE SCREEN · ONSITE INTERVIEW · Seen Oct 2026
  • Median Across N Sorted ArraysPHONE SCREEN · Seen Oct 2026

Similar questions at other companies

  • Detect a Straight FlushTemu · PHONE SCREENTemu interview questions
  • First Letter to Appear TwiceCisco · PHONE SCREENCisco interview questions
  • Halfway Course in a Single TrackCrunchyroll · PHONE SCREENCrunchyroll interview questions
  • Portfolio Valuation, Part 1Stripe · PHONE SCREENStripe interview questions
  • Single-Condition Product FilterCrowdstrike · PHONE SCREENCrowdstrike interview questions
  • Summarize Server Healthcheck LogsNVIDIA · PHONE SCREENNVIDIA interview questions
  • Known Words Matching Phone DigitsLinkedIn · PHONE SCREENLinkedIn interview questions
  • First Non-Repeated CharacterDell Technologies · PHONE SCREENDell Technologies interview questions
  • Convert an Entry List to a MapEPAM · PHONE SCREENEPAM interview questions
  • First Non-Repeating CharacterGoldman Sachs · PHONE SCREEN · ONSITE INTERVIEWGoldman Sachs interview questions

Interview reports that mention this question

  • Rippling No-Level Design, Screens: 30 Experiences (Part 2 of 6)
  • Rippling SWE Interviews, No Level: 156 Experiences (Part 1 of 6)

Rippling interview experiences

  • Rippling No-Level Older Reports: 31 Experiences (Part 6 of 6)
  • Rippling No-Level Onsite Loops: 24 Experiences (Part 5 of 6)
  • Rippling No-Level Screens and Loops: 18 Experiences (Part 4 of 6)
  • Rippling No-Level Coding Screens: 37 Experiences (Part 3 of 6)
All Rippling interview questionsSee Rippling hiring insights
Saved
class Solution {
    public String firstSingleCharacter(String s) {
        // Write your code here.
    }
}
Checking account…