- Home
- Interview Questions
- Aptitude
- How do you decode sentence-based codes where several words s…
Try answering first
In a real interview nobody shows you the answer. Think it through (or type it), then reveal the answers and rate yourself.
1 Answer
Short answer: Compare sentences two at a time. A word that appears in both sentences must take the code that appears in both coded versions. Fix these common pairs step by step, then use elimination for the remaining words. If a word's code could still be one of two options, the answer is 'cannot be determined'.
Detailed explanation
In this type of question, each English word maps to exactly one code word. However, the codes are usually not listed in the same order as the words. Position therefore tells you nothing, and the only reliable tool is set intersection.
The core logic: If a word appears in sentence 1 and sentence 2, its code must appear in both coded sentences. If exactly one word and exactly one code are common to two sentences, they are matched.
Systematic method:
- Write each sentence with its code directly beneath it.
- Take every pair of sentences and find the common words and the common codes.
- When a pair has a single common word and a single common code, record that match.
- Strike out matched words and codes everywhere. This often turns new pairs into single-common cases.
- When a sentence has only one unmatched word and one unmatched code left, those two belong together.
- For any word still left with two or more possible codes, the answer is 'cannot be determined'.
Why the question is hard: Examiners deliberately include words that appear in only one sentence. Their codes can be narrowed down but not always fixed. Recognising when information is insufficient is what this question actually tests.
Example
1. tam sik ro means good bright day
2. ro pul ken means day is long
3. pul sik ved means long good nightPairwise comparison:
- Sentences 1 and 2: the common word is day and the common code is ro, so day = ro.
- Sentences 2 and 3: the common word is long and the common code is pul, so long = pul.
- Sentences 1 and 3: the common word is good and the common code is sik, so good = sik.
Elimination:
- Sentence 1: removing good and day leaves bright = tam.
- Sentence 2: removing day and long leaves is = ken.
- Sentence 3: removing long and good leaves night = ved.
All six words are now decoded. If asked for the code for 'bright', the answer is tam.
The cannot-be-determined trap: Suppose only sentences 1 and 2 were given. You could still fix day = ro. However, 'good' could be either tam or sik, because nothing separates it from 'bright'. The correct answer would then be 'cannot be determined'. Choosing tam or sik would be a guess, and a correct guess still means faulty reasoning.
Common mistakes
- Assuming the codes follow the word order. This is usually false, and the examiner expects you to ignore position.
- Comparing only consecutive sentences. Sentences 1 and 3 often hold the key match.
- Choosing one of two possible codes instead of marking 'cannot be determined'.
- Not striking out matched words, which makes later comparisons confusing and error-prone.
Follow-up questions
- Using the same code, what would 'good night' most likely be coded as, and does code order matter in your answer?
- If a word appears in only one sentence and that sentence has two unmatched codes, how do you decide the answer?
- How would you approach a version where letters inside the code word also carry meaning, such as a common prefix for related words?
Interview tip: Say your reasoning aloud as 'common word, common code' for each pair. Interviewers care more about clean elimination logic than about speed.
Reviewed by the Interview Questions editorial team · Last updated
How well did you know this?
Rate yourself to track progress, build your streak and get “didn't know” questions in your revision list.
Your Answer
More hard Aptitude questions
- How do you calculate successive percentage changes and work backwards to find the original value? · 1 ans
- How do you solve coded blood relation questions where symbols stand for family relations? · 1 ans
- How do you calculate the liquid left after repeatedly removing some and replacing it with water? · 1 ans
Related Questions
- How do you solve coded blood relation questions where symbols stand for family relations? · Aptitude · 1 ans
- How do you solve 'pointing to a photograph' blood relation questions without getting confused? · Aptitude · 1 ans
- How do you pick the best synonym when two or more options seem correct? · Aptitude · 1 ans
- How do you solve coding-decoding questions where letters shift by fixed or varying positions? · Aptitude · 1 ans
- If the price of a commodity rises by 25%, by what percent must consumption fall to keep expenditure unchanged? · Aptitude · 1 ans
- How do you calculate successive percentage changes and work backwards to find the original value? · Aptitude · 1 ans
- How do you calculate the liquid left after repeatedly removing some and replacing it with water? · Aptitude · 1 ans
- How do you use the rule of alligation to find the ratio for mixing two items of different prices? · Aptitude · 1 ans
🙋 Was this asked in your interview?
Which company? (optional — adds this question to the company's page)