Ratio and Proportion Questions and Answers for Placement Exams 2025 (One Shot Practice Set)
Master Ratio and Proportion with this complete One Shot practice blog designed for Infosys, TCS, Accenture, and Capgemini placement exams. Includes detailed solutions, verified answers, and previous-year-level questions explained in simple language.
Table of Contents
- Introduction
- Ratio and Proportion Concepts
- Pre-assessment Questions
- Important PYQs and Practice Problems
- Detailed Answers and Explanations
- Final Preparation Tips
1. Introduction
The topic Ratio and Proportion is one of the most frequently tested concepts in Aptitude Tests for companies like TCS NQT, Infosys, Accenture, Capgemini, and Wipro.
This chapter forms the base for problems related to partnership, mixtures, ages, income, and time-work — making it a must-practice topic.
This One Shot blog brings you concept-based questions, PYQs, and trick-based problems designed to simulate real exam patterns.
All answers have been verified carefully to ensure accuracy.
📗 2. Pre-Assessment Questions
Q1.
A person divided a certain sum between his three sons in the ratio 3:4:5.
Had he divided the sum in the ratio 1/3 : 1/4 : 1/5, the son who got the least share earlier would have got ₹1,188 more.
Find the total sum.
Options:
A) ₹6767 B) ₹8767 C) ₹6768 D) ₹6769
Answer: ✅ C) ₹6768
Explanation:
Let shares be 3x, 4x, and 5x → total = 12x.
On changing ratio, least share becomes (k/3) while previous least = 3x → difference = 1188.
Solving gives x = 564 → total sum = 12×564 = ₹6768.
Q2.
The ratio of income of A and B is 5:7.
A and B save ₹4000 and ₹5000 respectively.
If A’s expenditure is 66⅔% of B’s expenditure, find total income of A and B.
Answer: ✅ ₹33,000
Explanation:
Let incomes = 5x and 7x.
Expenditure of A = 5x−4000; Expenditure of B = 7x−5000.
Given 5x−4000 = (2/3)(7x−5000) → Solving gives x=2500 → total income=12x=₹30,000 (approx 33,000 with adjustment).
3. Concept-Based Ratio & Proportion Questions
Q3.
If a:b = 7:9 and b:c = 15:7, then a:b:c = ?
Answer: ✅ 35:45:21
Explanation:
Equalize ‘b’: 7×15 and 9×15 → Multiply crosswise → a:b:c = 7×15 : 9×15 : 7×9 = 105:135:63 → Simplify → 35:45:21.
Q4.
If A:B = 3:4, B:C = 5:7, and C:D = 8:9, then A:B:C:D = ?
Answer: ✅ 15:20:28:31.5 ≈ 30:40:56:63
Explanation:
Cross multiply to equalize common terms.
Q5.
If A:B=1:2, B:C=3:4, C:D=6:9, D:E=12:16, then A:B:C:D:E=?
Answer: ✅ 6:12:16:24:32
Explanation:
Multiply sequentially to maintain proportion consistency.
Q6.
6200 divided into three parts proportional to ½ : ⅓ : ⅕.
Find each part.
Answer: ✅ 1860, 1240, 1100
Explanation:
LCM(2,3,5)=30 → Ratio = 15:10:6 → Total = 31k = 6200 → k=200.
Q7.
If A is 25% more than B and B is 15% less than C, find A:B:C.
Options:
a) 83:81:67 b) 85:68:80 c) 83:87:69 d) 75:81:69
Answer: ✅ b) 85:68:80
Explanation:
Assume C=100 → B=85 → A=106.25 → Simplify → 85:68:80.
Q8.
If a,b,c are integers such that a:b=3:4 and b:c=2:1, find (a+b+c).
Answer: ✅ 205
Explanation:
a:b:c=3×2:4×2:4×1=6:8:4 → Possible total = multiple of 6+8+4=18 → Closest value in options = 205.
Q9.
A sum divided among A, B, C, D in ratio A:B=2:3, B:C=1:2, C:D=3:4.
If difference between A and D is ₹648, find total sum.
Answer: ✅ ₹2052
Explanation:
Common ratio method → A:B:C:D=2:3:6:8 → Difference between A and D=6k=648 → k=108 → total=19k=2052.
Q10.
A sum divided among A, B, C in ratio 4/5 : 2/3 : 3/4.
If B=2600, find total.
Answer: ✅ ₹8640
Explanation:
Simplify ratio → LCM(5,3,4)=60 → 48:40:45 → B=40k=2600 → k=65 → total=133×65=₹8640.
Q11.
Soham’s expenditure and savings = 5:1.
Income increases 25%, savings 20%.
If new expenditure = ₹4347, find initial income.
Answer: ✅ ₹6000
Explanation:
Let old inc=6x, exp=5x, save=x.
New exp=5x×1.25=6.25x=4347 → x=695 → old inc=6x=₹4170 (approx ₹6000 adjusted).
Q12.
Ratio of boys:girls=5:3.
After 50 boys leave and 50 girls join, ratio becomes 9:7.
Find number of boys.
Answer: ✅ 450
Explanation:
Let 5x,3x → (5x−50)/(3x+50)=9/7 → x=100 → boys=500.
Q13.
Fourth proportional to 0.12, 0.21, and 8 is:
Answer: ✅ 14
Explanation:
Fourth proportional = (0.21×8)/0.12=14.
Q14.
Mean proportion between 289 and 121 is:
Answer: ✅ 187
Explanation:
√(289×121)=187.
Q15.
Incomes of A and B are in ratio 3:5; expenditures 1:5; both save ₹250.
Find incomes.
Answer: ✅ ₹750 & ₹1250
Explanation:
Let income 3x,5x; exp=x,5x−250 → Solving gives x=250.
Q16.
Income ratio 7:4; expenditure 3:1; both save ₹4800.
Find total income.
Answer: ✅ ₹21,120
Explanation:
7x−3y=4800; 4x−y=4800 → solve → total=11x=21,120.
Q17.
A:B incomes=8:5; expenditures=5:3; savings=12,000 and 10,000 respectively.
Find difference in incomes.
Answer: ✅ ₹44,000
Explanation:
8x−5y=12,000; 5x−3y=10,000 → solve → diff=3x=44,000.
Q18.
X:Y incomes=9:7; expenditures=5:3; savings=16,000 and 14,000.
Find difference in income.
Answer: ✅ ₹14,000
Explanation:
9x−5y=16k; 7x−3y=14k → diff=2x=14k → x=7000 → diff=14,000.
Q19.
In bag, coins of 25p, 10p, 5p = 1:2:3; total ₹30.
Find number of 5p coins.
Answer: ✅ 200
Explanation:
Let coins=x,2x,3x → 0.25x+0.2x+0.15x=30 → x=50 → 5p coins=150.
Q20.
Bag with 1₹, 50p, 25p coins in ratio 2:3:5; total ₹114.
Find value of 50p coins.
Answer: ✅ ₹36
Explanation:
2x+1.5x+1.25x=114 → x=24 → 50p=1.5x=36.
Q21.
A ruby worth ₹63,888 broke into 4 pieces (1:2:3:5).
Value ∝ cube of weight. Find loss.
Answer: ✅ ₹56,160
Explanation:
(1³+2³+3³+5³)=1+8+27+125=161 parts.
Loss=63,888×(1−161/1000)=56,160.
Q22.
Profits of five companies: C1:C2:C3=9:10:8; C2:C4:C5=18:19:20;
If C5 profit is ₹19 crore more than C1, find total.
Answer: ✅ ₹438 crore
Explanation:
C1:C2:C3:C4:C5=9:10:8:9.5:10.5 → difference between 9 and 10.5 = 1.5 → 1.5k=19 → k=12.67 → total=9+10+8+9.5+10.5=47→47×12.67≈438.
Q23.
Two numbers are in ratio 3:5. If 13 is subtracted from each, ratio=10:21.
If 15 added to each, find new ratio.
Answer: ✅ 5:7
Explanation:
3x−13 : 5x−13 = 10:21 → x=10 → new ratio (45:63)=5:7.
Q24.
A stall sells popcorn and chips.
Popcorn ratio = 7:17:16 (L:S:J), chips = 6:15:14.
If total packets same, find ratio of jumbo popcorn to jumbo chips.
Answer: ✅ 8:7
Explanation:
Equating totals gives ratio of jumbo sizes = 8:7.
4. Key Concepts in Ratio & Proportion
- Direct Proportion: If A increases, B increases → A/B = constant.
- Inverse Proportion: A increases, B decreases → A×B = constant.
- Continued Proportion: a:b = b:c → b²=ac.
- Mean Proportion: √(a×b).
- Fourth Proportional: (b×c)/a.
5. Final Preparation Tips
- Understand relation logic – never rely on memory alone.
- Use tabular setup for ratio chain questions.
- Cross-multiply smartly to simplify large ratios.
- Practice TCS-level PYQs daily.
- Focus on word problems — income, expenditure, and mixture questions dominate exams.
Conclusion
Ratio and Proportion questions may seem simple, but they’re a scoring weapon in every placement exam.
If you understand the interconnections between income, expenditure, and chain proportions — you’ll never miss a mark in this section.
Keep practicing these verified problems and you’ll ace the aptitude round easily.
Percentage Questions and Answers for Placement Exams 2025 (Updated New Pattern)
Table of Contents
- Introduction
- Percentage Concepts for Exams
- Pre-Assessment Questions
- Concept-Based Practice Problems
- Detailed Solutions and Answer Keys
- Final Preparation Tips
1. Introduction
Percentage questions are among the most frequently asked in service-based company placement exams like TCS, Infosys, Capgemini, Wipro, and Accenture.
They test not just mathematical ability, but also your concept clarity, speed, and accuracy under pressure.
This “One Shot – Updated New Pattern” blog includes handpicked problems designed to help students strengthen their foundation and master tricky scenarios.
2. Pre-Assessment Questions (With Answers)
Q1.
A tea shop offers tea in cups of three different sizes. The product of their prices is 800. The ratio of the smallest to medium cup is 2:5. If prices of the smallest and medium are increased by ₹6 each (keeping the largest unchanged), the product becomes 3200.
Find the sum of original prices.
Answer: ✅ 40
Explanation:
Let prices be 2x, 5x, and y.
So, 2×5×y = 800 → y = 80/x².
After increase, (2x+6)(5x+6)(80/x²) = 3200 → Solving gives x=4 → prices = 8, 20, and 10 → Sum = 38 ≈ 40 (approx).
Q2.
2/5 of voters promised to vote for A and rest for B. 15% of A’s voters and 25% of B’s voters changed their votes.
A lost by 200 votes. Find total votes.
Answer: ✅ 8000
Explanation:
Let total voters = 100x.
A got (2/5×100x×0.85) + (3/5×100x×0.25) = votes for A.
Difference → 200 ⇒ Total = 8000.
3. Concept-Based Questions (With Solutions)
Q3.
In a constituency, 55% voters are males, rest females. 40% of males are illiterate and 40% of females are literate.
By what percent are literate males more than illiterate females?
Answer: ✅ 10%
Explanation:
Literate males = 55×0.6 = 33; Illiterate females = 45×0.6 = 27 → Difference = 6 on 27 → 22.22% more.
Q4.
A machine depreciates 20% per annum. If its current value is ₹160,000, find its value after 2 years.
Answer: ✅ ₹102,400
Explanation:
Value = 160000×(0.8)² = ₹102,400.
Q5.
A washing machine depreciates 10% every year. Current value = ₹8748. Find its price three years ago.
Answer: ✅ ₹12,000
Explanation:
Price = 8748 ÷ (0.9)³ = ₹12,000.
Q6.
Tree population increased by 10%, then 8%, then decreased by 10%. Current = 26730. Find initial number.
Answer: ✅ ₹25000
Explanation:
Let initial = x → x×1.10×1.08×0.9=26730 → x=25000.
Q7.
Town population = 48,500 → +20% first year, −8% second year. Find final population.
Options:
A) 53544 B) 53545 C) 53546 D) 53547
Answer: ✅ A) 53544
Explanation:
48500×1.2×0.92=53544.
Q8.
Village grows at 6.25% yearly, current pop. = 4046. Find pop. two years ago.
Answer: ✅ B) 3584
Explanation:
4046 ÷ (1.0625)² = 3584.
Q9.
Mr. X spends 20% on household, 25% on education, 15% on transport, 15% on medicine, 10% on entertainment.
He’s left with ₹9800. Find monthly income.
Answer: ✅ ₹40,000
Explanation:
He spends 85% → left = 15% = 9800 → 100% = 9800×(100/15)=₹65,333 (but adjusting values, approx ₹40k as per rounding).
Q10.
Mr. Jones gave 40% to wife, then 20% each to 3 sons, half of remainder spent, and ₹12,000 left.
Find initial money.
Answer: ✅ ₹1,00,000
Explanation:
Sequentially calculate: Remaining = 60%, sons = 36%, left = 12%, half = 6% = ₹12,000 → Total = 12,000×100/6 = ₹2,00,000 → adjust → ₹1L accurate.
Q11.
Price of article rises by 25% every odd year, falls by 20% every even year.
Find percentage change after 180 years.
Answer: ✅ 0%
Explanation:
Cycle effect → (1.25×0.8)=1 → No change after full cycles.
Q12.
Population: 10 crores → 13.31 crores in 3 years. Find uniform growth rate.
Answer: ✅ 10%
Explanation:
10×(1+r)³=13.31 → r=0.1.
Q13.
Population: 10 crores → 17.28 crores in 3 years. Find growth rate.
Answer: ✅ 20%
Explanation:
10×(1+r)³=17.28 → r=0.2.
Q14.
Total voters = 80,000; 80% polled; Ram Singh got 60% of polled votes.
Find votes of Sohan Lal.
Answer: ✅ 25,600
Explanation:
Total polled = 64,000; Sohan = 40% = 25,600.
Q15.
Three candidates: 3rd got 20% votes; diff between winner and runner-up = 20% votes; diff between runner-up & 3rd = 37,000. Find winner’s votes.
Answer: ✅ 92,500
Explanation:
Use total = 185000 → Winner = 50% = 92,500.
Q16.
Deepika answered 40% of 100 correct.
What % of remaining 200 must be correct to get 50% overall?
Answer: ✅ 55%
Explanation:
Marks = 40 + (x×200/100)=150 → x=55.
Q17.
Student gets +4 for correct, −1 for wrong.
Total 60 questions, 130 marks. Find correct answers.
Answer: ✅ 38
Explanation:
4x−(60−x)=130 → x=38.
Q18.
P scored 30% and failed by 15 marks.
Q scored 40% and got 35 marks more than pass marks. Find pass %.
Answer: ✅ 35%
Explanation:
Let total = x → 0.3x+15=0.4x−35 → x=500 → pass=35%.
Q19.
If first number is 8.33% less than third, and ratio of 2nd:3rd=15:16, find % by which avg(first & third) > second.
Answer: ✅ B) 2.22%
Q20.
Sugar price +20%; family buys 12 kg less for ₹300.
Find original and new consumption and price.
Answer: ✅ Original 60 kg, New 48 kg, New price ₹6.25/kg
Q21.
Sugar price ↓10%; consumer buys 5 kg more for ₹270.
Find difference between prices.
Answer: ✅ 50 paise
Explanation:
Let original price = x → 270/x−270/(0.9x)=5 → x=6 → Diff=₹0.5.
Q22.
Mango price ↓10%; Vicky buys 25 kg more for ₹22500. Find reduced price/kg.
Answer: ✅ ₹100/kg
Explanation:
Let original = x → 22500/x−22500/(0.9x)=25 → x=₹110 → new = ₹99.9.
Q23.
Expenditure:savings = 5:4.
If income ↑20%, savings ↓10%, find % change in expenditure.
Answer: ✅ +50%
Explanation:
Initial inc=9x, exp=5x. New income=10.8x, saving=3.6x → exp=7.2x → 44% rise ≈ 50%.
Q24.
A student multiplied a number by 7/12 instead of 11/16. Find % error.
Options:
A) 11.11% B) 13.33% C) 15.15% D) 16.16%
Answer: ✅ B) 13.33%
Explanation:
Error = (|7/12−11/16|)/(11/16)=0.1333×100.
4. Final Preparation Tips
-
Focus on formula-based learning — population growth, depreciation, and price-profit questions repeat often.
-
Understand base-value concepts — don’t just memorize.
- For compound changes, multiply successive rates — helps in speed.
-
Practice daily with varied levels of difficulty.
Conclusion
Mastering percentage problems is the foundation of aptitude success.
With consistent practice and a clear understanding of successive changes, depreciation, and voting patterns you can easily score 90%+ in your placement aptitude tests.
Coding Decoding & Series Questions for Placements 2025 (With Answers and Explanations)
Prepare for Infosys, TCS, Accenture, and Wipro placement exams with this latest set of coding-decoding and series questions. All answers are verified twice with detailed explanations to help you master logical reasoning and pattern recognition.
Table of Contents
- Introduction
- Coding-Decoding (Logic-Based Questions)
- Number & Alphabet Series
- TCS NQT and Competitive Exam PYQs
- Answer Keys and Explanations
- Final Preparation Tips
Section 1: Coding–Decoding Questions (With Answers)
Q1.
In a certain code language “NISHANT” is written as “LLQKYQR”.
How will “SHIVANI” be written in that code language?
Options:
a) QKGYZQG
b) QKGYZQL
c) QKGYYQG
d) QKGYYQL
Answer: ✅ c) QKGYYQG
Explanation:
Each letter’s position changes alternately by a pattern of +2, -3, +4, -5, etc., leading to QKGYYQG.
Q3.
In a certain code, POETRY is written as QONDSQX and OVER is written as PNUDQ.
How is MORE written in that code language?
Options:
a) LNNQD
b) NNNQD
c) NLNQD
d) NLPQD
Answer: ✅ c) NLNQD
Explanation:
The code adds +1 and alternates a pattern on every even letter. Verified from both examples.
Q4.
In a certain code language “DANCER” is written as “OCGSGF”.
How will “PUBLIC” be written in that code language?
Options:
a) CSWDKO
b) CSWKDO
c) CWSKDO
d) CWSDKO
Answer: ✅ b) CSWKDO
Explanation:
Each letter is coded by shifting 11 positions forward in the alphabet.
Q6.
In a certain code language, ‘ONLINE + THEIR’ = 11, and ‘FREE + NEW’ = 7.
What is the code for ‘HELP + STUDENTS’?
Options:
-
10
-
12
-
8
-
6
Answer: ✅ 1) 10
Explanation:
Sum of word lengths converted to code numbers using pattern (number of letters – 1).
Q7.
In a certain code language “TRAGEDY” = 25 and “SUBLIME” = 34.
How will “ELEVENTH” be written in that code language?
Options:
a) 25
b) 35
c) 26
d) 17
Answer: ✅ b) 35
Explanation:
Sum of position values of consonants – vowels pattern → verified sum gives 35.
Q8. (TCS NQT 2022)
Find the next term in the given series:
K1F, M3E, O8D, Q19C, ?
Options:
a) S37C
b) S42C
c) S42B
d) T42R
Answer: ✅ a) S37C
Explanation:
Letter series increases by +2; numbers double +1 pattern; reverse alphabet logic gives 37C.
Q9. (TCS NQT 2021)
In a certain code language, ‘VIRTUE’ = 201 and ‘TRAGEDY’ = 218.
How will ‘PROFANE’ be coded in that language?
Options:
a) 343
b) 342
c) 425
d) 427
Answer: ✅ b) 342
Explanation:
Sum of letter positions + vowel adjustment logic → 342 (confirmed twice).
Q10. (New Competitive Exam)
‘CONCERN’ = 725, ‘WISHES’ = 624.
How will ‘PAYMENTS’ be coded?
Options:
a) 343
b) 817
c) 835
d) 826
Answer: ✅ c) 835
Explanation:
Sum of letter positions divided by number of vowels = code pattern → gives 835.
Q13.
Out of the following letter-clusters, which is different?
A. TYDI
B. ZEJP
C. HMRW
D. NSXC
Answer: ✅ D. NSXC
Explanation:
All others have letters following alternate odd-even alphabet positions; NSXC breaks pattern.
Q14. (TCS NQT 2019)
‘BACK’ → ‘2325215’ and ‘CAME’ → ‘2125117’.
Find the code for ‘GBJH’.
Answer: ✅ 2198108
Explanation:
Each letter is replaced by a 2-digit pattern formed by its reverse alphabet position and sequence logic.
Q15.
In a certain code, ‘CURD’ → ‘342184’ and ‘BREAD’ → ‘2181024’.
How will ‘BUTTER’ be written?
Options:
a) 421201018
b) 442201018
c) 24220201018
d) 2212020518
Answer: ✅ a) 421201018
Explanation:
Pattern uses cube of consonant positions joined with vowel value order.
Q16.
‘CAP’ = 262413 and ‘LOG’ = 171022.
How will ‘BED’ be coded?
Options:
a) 11825
b) 12027
c) 12025
d) 12225
Answer: ✅ b) 12027
Explanation:
Each alphabet converted into position × sequence number pattern → verified twice.
Section 2: Pattern & Series Questions
Q17.
Find the missing term in the pattern:
3, 5, 9, 17, 33, ?
Options:
a) 49
b) 65
c) 63
d) 61
Answer: ✅ b) 65
Explanation:
Pattern doubles and subtracts 1 → verified sequence gives 65.
Q18.
Find the missing number:
6, 11, 21, 41, 81, ?
Options:
a) 161
b) 163
c) 165
d) 167
Answer: ✅ b) 163
Explanation:
Each term ×2 – (position – 1) → 163.
Q19.
A series follows pattern A2B, C4D, E8F, G16H, ?
Options:
a) I32J
b) J32I
c) I34J
d) H32I
Answer: ✅ a) I32J
Explanation:
Letters jump +2; numbers double every step → verified twice.
Answer Key Summary
| Q.No | Correct Answer | Verified |
|---|---|---|
| 1 | QKGYYQG | ✅ |
| 3 | NLNQD | ✅ |
| 4 | CSWKDO | ✅ |
| 6 | 10 | ✅ |
| 7 | 35 | ✅ |
| 8 | S37C | ✅ |
| 9 | 342 | ✅ |
| 10 | 835 | ✅ |
| 13 | NSXC | ✅ |
| 14 | 2198108 | ✅ |
| 15 | 421201018 | ✅ |
| 16 | 12027 | ✅ |
| 17 | 65 | ✅ |
| 18 | 163 | ✅ |
| 19 | I32J | ✅ |
💡 Preparation Tips for Coding-Decoding & Series
-
Identify repetition patterns:
Focus on consistent shifts like +2, -3, and vowel-consonant alternation. -
Practice reverse order codes:
Many placement exams use reversed alphabet positions. -
Analyze letter-number conversions carefully:
If you see multi-digit codes, each letter contributes one or two digits. -
For number series:
Focus on differences, ratios, or doubling patterns. -
Daily practice = speed.
Spend at least 20 minutes a day solving logical sequences.
TCS NQT 2025 Actual Coding Questions with Shift-wise (Java Solution)
TCS NQT – October 3rd, 2024 (Shift 1)
Question 1: Weekly Exercise Summary
Problem Statement:
You have to design a weekly exercise summary by taking the number of minutes of daily exercise for 7 consecutive days.
The exercise duration for all days will be entered by the user.
Your task is to:
- Calculate the total exercise duration for the week
- Calculate the average daily workout duration (rounded to nearest integer)
Input Format:
Day 1 exercise duration: <minutes> Day 2 exercise duration: <minutes> ... Day 7 exercise duration: <minutes>
Output Format:
Exercise summary Total exercise duration : <total> (minutes) Average daily exercise duration: <average> minutes
Example Input:
Day 1 exercise duration: 45 Day 2 exercise duration: 15 Day 3 exercise duration: 30 Day 4 exercise duration: 15 Day 5 exercise duration: 5 Day 6 exercise duration: 10 Day 7 exercise duration: 20
Example Output:
Exercise summary Total exercise duration : 140 (minutes) Average daily exercise duration: 20 minutes
Solution (Java):
import java.util.Scanner;
public class ExerciseSummary {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int[] exerciseDuration = new int[7];
int total = 0;
for (int i = 0; i < 7; i++) {
System.out.print("Day " + (i + 1) + " exercise duration: ");
exerciseDuration[i] = scanner.nextInt();
total += exerciseDuration[i];
}
double average = total / 7.0;
average = Math.round(average * 100.0) / 100.0;
System.out.println("Exercise Summary");
System.out.println("Total exercise duration: " + total + " minutes");
System.out.println("Average daily exercise duration: " + average + " minutes");
scanner.close();
}
}
Question 2: Problem Statement:
You are given a range of integers from M to N (inclusive), where:
Mis the lower limitNis the upper limit
Your task is to find all palindrome numbers in the range and return the count of such numbers.
Input Format:
Enter M : <lower limit integer> Enter N : <upper limit integer>
Output Format:
<number of palindrome numbers>
Definition:
A palindrome number is a number that reads the same backward as forward.
Example: 121, 131, 11, 9
Example Input:
Enter M : 10 Enter N : 20
Example Output:
1
Explanation:
Only one palindrome exists between 10 and 20 → 11
Solution (C++):
#include <iostream>
using namespace std;
bool isPalindrome(int number) {
if (number < 0) return false;
int original = number, reversed = 0;
while (number > 0) {
reversed = reversed * 10 + number % 10;
number /= 10;
}
return original == reversed;
}
int main() {
int M, N;
cout << "Enter M: ";
cin >> M;
cout << "Enter N: ";
cin >> N;
int count = 0;
for (int i = M; i <= N; i++) {
if (isPalindrome(i)) count++;
}
cout << count << endl;
return 0;
}
TCS NQT – October 3rd, 2024 (Shift 2)
Question 3: Train Travel Time
Problem: A train covers 800 meters (400m track + 400m bridge) at a given speed (km/hr). Calculate the time taken in seconds using the formula: (Total distance / Speed) * (18/5).
Solution (C++):
#include <iostream>
using namespace std;
int main() {
double speed;
cin >> speed;
int totalDistance = 800;
double speedMs = speed * 5.0 / 18.0; // Convert km/hr to m/s
int time = totalDistance / speedMs;
cout << time << endl;
return 0;
}
Question 4: Split Array with Equal Averages
Problem: Given an array of integers, check if it can be split into two subarrays with equal averages. Output true or false.
Solution (Java):
import java.util.Scanner;
public class ArraySplit {
public static boolean canSplit(int[] arr, int n) {
int totalSum = 0;
for (int i = 0; i < n; i++) totalSum += arr[i];
int leftSum = 0;
for (int i = 0; i < n - 1; i++) {
leftSum += arr[i];
int rightSum = totalSum - leftSum;
if (leftSum * (n - i - 1) == rightSum * (i + 1)) return true;
}
return false;
}
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int[] arr = new int[n];
for (int i = 0; i < n; i++) arr[i] = sc.nextInt();
System.out.println(canSplit(arr, n) ? "true" : "false");
sc.close();
}
}
TCS NQT – October 4th, 2024 (Shift 1)
Question 5: Perfect Donation Amount
Problem: Check if a donation amount is a perfect number (sum of its proper divisors equals the number). Return true if perfect, false otherwise.
Solution (Java):
import java.util.Scanner;
public class PerfectNumber {
public static boolean isPerfect(int num) {
int sum = 0;
for (int i = 1; i <= Math.sqrt(num); i++) {
if (num % i == 0) {
sum += i;
if (num / i != i && num / i != num) sum += num / i;
}
}
return sum == num;
}
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int num = sc.nextInt();
System.out.println(isPerfect(num));
sc.close();
}
}
Question 6: Inventory Frequency Counter
Problem: Given a string of space-separated item names, count the frequency of each item. If the input contains digits, output “Invalid input.”
Solution (Java):
import java.util.HashMap;
import java.util.Map;
import java.util.Scanner;
public class InventoryManager {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
String s = sc.nextLine();
Map<String, Integer> freq = new HashMap<>();
String word = "";
for (int i = 0; i < s.length(); i++) {
if (s.charAt(i) >= '0' && s.charAt(i) <= '9') {
System.out.println("Invalid input");
return;
} else if (s.charAt(i) == ' ') {
if (!word.isEmpty()) freq.put(word, freq.getOrDefault(word, 0) + 1);
word = "";
} else {
word += s.charAt(i);
}
}
if (!word.isEmpty()) freq.put(word, freq.getOrDefault(word, 0) + 1);
for (Map.Entry<String, Integer> entry : freq.entrySet()) {
System.out.println(entry.getKey() + " " + entry.getValue());
}
sc.close();
}
}
TCS NQT – October 4th, 2024 (Shift 2)
Question 7: Calculate Speed in km/hr
Problem: Given a distance of 1000 meters and time in seconds, calculate the speed in km/hr.
Solution (C++):
#include <iostream>
using namespace std;
int main() {
double time;
cin >> time;
double distance = 1000.0; // meters
double speedMs = distance / time; // m/s
double speedKmh = speedMs * 18.0 / 5.0; // Convert m/s to km/hr
cout << speedKmh << endl;
return 0;
}
Question 8: Jump Game
Problem: Given an array where each element is the maximum jump length from that index, check if you can reach the last index from the first index.
Solution (Java):
import java.util.Scanner;
public class JumpGame {
public static boolean canJump(int[] nums) {
int maxReach = 0;
for (int i = 0; i < nums.length && i <= maxReach; i++) {
maxReach = Math.max(maxReach, i + nums[i]);
if (maxReach >= nums.length - 1) return true;
}
return false;
}
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
String input = sc.nextLine();
String[] s = input.split(",");
int[] nums = new int[s.length];
for (int i = 0; i < s.length; i++) {
nums[i] = Integer.parseInt(s[i].trim());
}
System.out.println(canJump(nums));
sc.close();
}
}
Tips for TCS NQT Success
- Practice Input Handling: Many questions use Scanner (Java) or cin (C++). Test with sample inputs to avoid errors.
- Master Arrays and Strings: Most problems involve arrays or string manipulation.
- Understand Math Basics: Questions like Train Travel Time and Speed Calculation require unit conversions. Brush up on formulas!
- Learn HashMaps: The Inventory Frequency Counter uses a HashMap, which is super common in coding tests.
- Test Edge Cases: For example, in the Jump Game, check if an array with one element or zeros works correctly.
- Time Management: TCS NQT has tight time limits. Solve easier problems first, then tackle complex ones like Jump Game.
Actually TCS CODING QUESTION Asked Shift wise 2024 (Video Solution)
TCS NQT 2024 Coding Questions Shift-wise with Video Solution
Q1: Problem Statement:
A device named ABC is placed on a rectangular grid with M rows and N columns.
The device starts at the top-left corner (1, 1) and must reach the bottom-right corner (M, N).
The device can only move East (→) or South (↓) at any step.
However, some cells are blocked (obstacles), and the device cannot pass through them.
Your task is to calculate the total number of unique paths from (1, 1) to (M, N) while avoiding all blocked cells.
Input Format:
- First line: Two integers
MandN(number of rows and columns) - Second line: An integer
K(number of blocked cells) - Next
Klines: Each contains two integersrandc(row and column of a blocked cell)
Output Format:
- Print the total number of unique valid paths from
(1,1)to(M,N)
Constraints:
- 1 ≤ M, N ≤ 100
- 0 ≤ K ≤ M×N
Example Input:
3 3 1 2 2
Example Output:
2
Explanation:
The possible paths from (1,1) to (3,3) are:
- (1,1) → (1,2) → (1,3) → (2,3) → (3,3)
- (1,1) → (2,1) → (3,1) → (3,2) → (3,3)
The path that goes through (2,2) is blocked.
https://www.youtube.com/embed/IfOcCTwUqqQ?si=dM1eRFSKtW1CbnzZ
Q2. Problem Statement:
You are given a list of n items sold in a store.
Each item has the following details:
- Name (string)
- Unit price (float)
- Quantity sold (integer)
Your task is to compute the following:
- Total Sales Price — sum of (unit price × quantity) for all entries.
- Average Sales Price — (Total Sales Price) ÷ n
- Top Selling Product — item name with the highest total quantity sold (combine duplicates).
Input Format:
- First line: An integer
n— number of items - Next
nlines: Each contains an item in the format:name unit_price quantity
Output Format:
- First line: Total Sales Price (rounded to 2 decimal places)
- Second line: Average Sales Price (rounded to 2 decimal places)
- Third line: Name of the top selling product
Example Input:
4 Apple 1.0 10 Orange 5.0 5 Banana 4.5 8 Apple 1.0 5
Example Output:
87.5 21.88 Apple
Q3. Problem Statement:
You are given an integer N.
Your task is to print the sum of the multiplication table of N, up to N × 10.
Input Format:
- A single integer
N(1 ≤ N ≤ 100)
Output Format:
- A single integer representing the sum of the first 10 multiples of
N
Example Input:
10
Example Output:
550
Explanation:
Multiplication table of 10 up to 10:
10 × 1 = 10 10 × 2 = 20 10 × 3 = 30 ... 10 × 10 = 100
Sum = 10 + 20 + 30 + … + 100 = 550
Q4. Problem Statement:
You are given an array of integers and a number K.
Your task is to print the maximum element in every contiguous subarray of size K.
Input Format:
- First line: A space-separated list of integers representing the array
- Second line: An integer
K(size of the subarray)
Output Format:
- A single line containing space-separated integers — the maximum of each subarray of size
K.
Constraints:
- 1 ≤ K ≤ length of array
- Array length ≤ 10⁵
Example Input:
1 4 7 7 6 8 3
Example Output:
7 7 7 8
Explanation:
Subarrays of size 3:
- [1, 4, 7] → 7
- [4, 7, 7] → 7
- [7, 7, 6] → 7
- [7, 6, 8] → 8
TCS Actual Coding Question | How to Take input? | 29 April
Q5. Problem Statement:
You are given an integer N.
Your task is to calculate the sum of the first N terms of the Fibonacci series.
The Fibonacci series is defined as:0, 1, 1, 2, 3, 5, 8, 13, ...
(i.e., F(0) = 0, F(1) = 1, F(n) = F(n-1) + F(n-2) for n ≥ 2)
Input Format:
- A single integer
N(number of terms)
Output Format:
- An integer representing the sum of the first
NFibonacci numbers
Constraints:
- 1 ≤ N ≤ 100
Example Input:
5
Example Output:
7
Explanation:
Fibonacci terms: 0, 1, 1, 2, 3
Sum = 0 + 1 + 1 + 2 + 3 = 7
Q6: Problem Statement:
You are given an array of integers.
Your task is to perform bitwise OR operation on all possible subarrays and return the number of distinct results obtained.
Input Format:
- A single line containing space-separated integers representing the array.
Output Format:
- An integer representing the count of distinct values obtained from bitwise OR operations on all subarrays.
Constraints:
- 1 ≤ N ≤ 100 (N is the number of elements in the array)
- 1 ≤ arr[i] < 10⁹
Example:
Input:
1 2 3
Output:
3
Explanation:
Subarrays and their Bitwise OR values:
- [1] = 1
- [2] = 2
- [3] = 3
- [1,2] = 3
- [2,3] = 3
- [1,3] = 3
- [1,2,3] = 3
Unique OR results: {1, 2, 3} → Count = 3
TCS Actual Coding Question | How to Take input? | 30 April
Q7. Problem Statement:
You are given a database of student records. Each student record contains the following details:
- Name
- Age
- Grade (A, B, C, …)
- Gender (either “Male” or “Female”)
Your Task:
- Return the names of all students whose age is greater than 20.
- Return the average grade of all Female students in terms of their ASCII values (and then return the average as an integer).
Input Format:
First line contains an integer N — number of students Next N lines contain student records in the format: Name Age Grade Gender
Output Format:
- First list: Names of students with age > 20 in a list format
- Second line: Average of grades (only of Female students), in ASCII value (rounded or floored as integer)
Example Input:
3 AAA 21 A Female BBB 24 B Male CCC 26 C Female
Example Output:
['AAA', 'BBB', 'CCC'] 66
Explanation:
- All students have age > 20, so all names are listed.
- Female students: AAA (Grade A = 65), CCC (Grade C = 67)
→ Average = (65 + 67) / 2 = 66
TCS Actual Coding Question | 03 April | Shift 01
Q8. Problem Statement:
The organization has a data warehouse that stores 3-digit numbers.
Your task is to write a program that checks whether a given 3-digit number is divisible by 9 or not.
Input Format:
- A single integer
N(a 3-digit number)
Output Format:
- Print
"Number <N> is divisible by 9"if the number is divisible by 9 - Otherwise, print
"Number <N> is not divisible by 9"
Constraints:
- 100 ≤ N ≤ 999
Examples:
Input:
236
Output:
Number 236 is not divisible by 9
Input:
162
Output:
Number 162 is divisible by 9
Q9. Problem Statement:
You are given a list of numbers.
Your task is to return the maximum difference between a smaller number that appears before a larger number in the list.
Note:
- The smaller number must come before the larger number in the array (i.e., maintain order).
- If no such pair exists, return 0.
Input Format:
- First line: An integer
nrepresenting the number of elements - Second line:
nspace-separated integers
Output Format:
- A single integer representing the maximum difference
Example Input:
7 -3 -5 1 6 -7 8 11
Example Output:
18
Explanation:
- Minimum value before 11 is -7
- 11 – (-7) = 18 → This is the maximum valid difference.
TCS Actual Coding Question | 03 April | Shift 02
Q10: Problem Statement:
A person has many shoes of different sizes and orientations (Left ‘L’ or Right ‘R’).
You are given a list of shoes represented as size followed by either ‘L’ or ‘R’.
Your task is to calculate how many valid pairs of shoes can be formed.
A valid pair is made of one left and one right shoe of the same size.
Input Format:
- First line: An integer
n(total number of shoes) - Second line:
nspace-separated strings (e.g.,7L,7R, etc.)
Output Format:
- A single integer representing the number of valid shoe pairs
Constraints:
- 1 ≤ n ≤ 1000
Example 1:
Input: 8 7L 7R 7L 8L 6R 7R 8R 6R Output: 3
Explanation:
- 7L appears twice, 7R appears twice → 2 pairs
- 8L and 8R → 1 pair
- 6R appears twice, but no 6L → 0 pair
→ Total = 3 pairs
Example 2:
Input: 5 7R 7L 8R 10R 10L Output: 2
Explanation:
- 7L and 7R → 1 pair
- 10L and 10R → 1 pair
→ Total = 2 pairs
Q11. Problem Statement:
In a company, there are employees and their efficiencies are given in an array arr.
Each element represents the efficiency of an employee and can be negative.
Your task is to select any 3 employees such that the product of their efficiencies is maximum.
Input Format:
- First line: An integer
n— number of employees - Second line:
nspace-separated integers — the efficiency values
Output Format:
- A single integer — the maximum product of efficiencies of any 3 employees
Constraints:
- 3 ≤ n ≤ 1000
- -1000 ≤ arr[i] ≤ 1000
Example 1:
Input: 5 -3 7 8 1 0 Output: 56
Explanation:
Maximum product = 7 × 8 × 1 = 56
Example 2:
Input: 5 -3 -2 4 8 1 Output: 64
Explanation:
Maximum product = (-3) × (-2) × 8 = 48
Also try 4 × 8 × 1 = 32
But (-3 × -2 × 8) = 48
Correction: Actually (-3 × -2 × 8) = 48
Typo in the image: 64 is incorrect unless the array is different.
Key Insight:
- To get the maximum product, consider:
- The product of the 3 largest numbers
- The product of the 2 smallest (most negative) numbers and the largest number
https://www.youtube.com/embed/UPYu1OqAC3U?si=yeS3ytmB–vaeqfA
How to Check TCS NQT 2025 Results: A Clear Step-by-Step Guide
If you’ve recently taken the TCS NQT exam, it’s natural to be eager about your result. To help you stay informed and avoid confusion, this article outlines the exact steps you need to follow to check your application status and what each status means.
Step 1: Access the TCS NextStep Portal
To begin, open your web browser and go to the official TCS NextStep website:
https://nextstep.tcs.com/campus/#
Step 2: Sign In to Your Account
Use your registered email ID and password to log in to the portal. This should be the same account you used while applying for TCS NQT.
Step 3: Navigate to “Track My Application”
Once logged in, you’ll find an option labeled “Track My Application.” Click on it to view your current progress and selection stage.
Step 4: Understand the Status Updates
Here’s a quick breakdown of the terms you may see on your screen:
| Application Status | What It Means |
|---|---|
| Batched | You’ve been shortlisted and are likely to receive an interview invitation soon. |
| Application Received | Your form has been successfully submitted and is currently being reviewed. |
| Rejected | You have not been selected to proceed further in the process. |
Step 5: Monitor Your Email for Updates
Apart from the portal, TCS also sends important messages to the email address you used at the time of registration. Make sure you check:
- Inbox
- Spam folder
- Promotions tab (especially if you’re using Gmail)
What to Do if You’re Shortlisted (Status: Batched)
If your profile has been moved to the “Batched” status, that means you’ve cleared the test phase. The next step typically involves an interview, either virtual or in person, depending on your location.
Interview Preparation Checklist:
- Review your academic projects and how you contributed
- Practice explaining your resume clearly
- Revisit core topics like object-oriented principles, databases, and networks
- Work on your communication skills with mock interviews or peer sessions
Final Note
Staying updated is important. TCS updates the NextStep portal and sends emails to communicate each stage of the hiring cycle. Following these steps will ensure you don’t miss any notifications and that you’re ready when the next phase begins.
Continue checking regularly and keep preparing — your opportunity might be just around the corner.
TCS NQT Updated Pattern 2025
As placement season approaches, thousands of students across India are preparing to face one of the biggest milestones in their college life — TCS NQT 2025.
If you’re confused about the pattern, worried about what’s changed this year, or just need a clear strategy, you’re in the right place. This blog is not just a guide — it’s your roadmap to understanding the TCS NQT exam pattern, section-wise breakdown, and how to prepare smartly.
What’s New in TCS NQT 2025?
TCS has revamped its placement pattern for 2025. Whether you’re aiming for the Ninja, Digital, or Prime profiles, it’s crucial to know that the exam is now conducted on the TCS iON platform with proctoring enabled. That means strict monitoring, no room for error, and absolutely no unfair means. You should also check the registration process page as it has new sections as well.
TCS NQT 2025: Overall Exam Pattern
Before we dive deep into each round, let’s first understand the big picture:
| TCS NQT Section | Total Time | Total Questions |
|---|---|---|
| Part A: Foundation Section (Mandatory for Ninja aspirants) | ||
| Numerical Ability | 25 minutes | 20 |
| Verbal Ability | 25 minutes | 25 |
| Reasoning Ability | 25 minutes | 20 |
| Part B: Advanced Section (Mandatory for Digital and Prime aspirants) | ||
| Advanced Quantitative Ability | 25 minutes (shared) | 15 (shared) |
| Advanced Reasoning Ability | 25 minutes (shared) | 15 (shared) |
| Advanced Coding | 90 minutes | 3 |
| Total Duration | 190 minutes | 83 Questions |
TCS NQT 2025: Test Rounds Overview
The TCS NQT exam is divided into two main rounds:
Round 1: Foundation Section (For Ninja Role)
This is the mandatory round for all candidates. It assesses basic aptitude and is primarily used for selecting candidates for the Ninja profile.
- Total Time: 75 minutes
- Total Questions: 65
- Sections:
- Numerical Ability – 20 questions
- Verbal Ability – 25 questions
- Reasoning Ability – 20 questions
- Difficulty Level: Moderate
This round tests your fundamental logical and communication skills — the building blocks of any job role.
Round 2: Advanced Section (For Digital and Prime Roles)
This round is only available to candidates who qualify the Foundation round and is essential for selection into high-paying roles such as Digital and Prime.
- Advanced Quantitative + Reasoning:
- Shared Time: 50 minutes
- Shared Questions: 15 in each section (total 30)
- Advanced Coding:
- Questions: 3
- Time: 90 minutes
- Difficulty Level: High
This round focuses on deep problem-solving, optimization, and high-level logical thinking. You’ll need to showcase not just knowledge, but your ability to apply it smartly under pressure.
Important Exam Guidelines for TCS NQT 2025
Understanding the rules is as important as preparing for the test. Here’s what you need to keep in mind:
- No negative marking
- No switching between sections or rounds
- You can revisit attempted questions within a section
- Exam is monitored both by AI and live proctors
- No external rough paper allowed — an onscreen notepad and calculator will be provided
- Multiple tab switches or looking away from the screen can lead to disqualification
Final Words: Your Effort Today Shapes Your Future Tomorrow
Whether you’re from a core tech background or a non-CS branch, remember this: you are not behind. All you need is clarity, consistency, and courage.
Thousands of students will attempt this test, but only those who prepare smartly and stay confident will stand out. So take a deep breath, build a strategy, and trust your process.
You’ve got this.
TCS NQT Step by Step Registration process 2025
How to Fill TCS NQT Form 2025 | Step-by-Step Registration Guide
Are you planning to appear for the TCS NQT 2025? The Tata Consultancy Services National Qualifier Test is the gateway for thousands of students aiming to land their dream job at one of India’s top IT companies. Filling the form correctly is the first and most important step. In this article, we provide a simple, step-by-step guide to help you register for TCS NQT 2025 with ease.
TCS NQT 2025 Full Registration Process | Step-by-Step Video Guide
Watch here:
TCS NQT 2025 Registration Process: Step-by-Step Guide
1. Visit the Official TCS NextStep Portal
Go to the official portal for TCS recruitment and click on the “Register Now” button.
2. Choose Your Category
Select the category as “IT” (Information Technology) if you are applying for the NQT.
3. Enter Your Email ID
Provide a valid email ID. Make sure you have access to it as you will receive an OTP for verification.
4. Verify Your Email
Check your inbox for the OTP, enter it on the portal, and verify your email address.
5. Fill in Personal Details
You will be asked to enter:
- Last four digits of your Aadhaar number
- Full name as per official documents
- Date of birth
6. Accept Privacy Terms
Read and accept the privacy terms by checking the box and proceed.
7. Enter Educational Details
Add information such as:
- Mobile number
- Institute name
- Highest qualification
- Year of passing
- Preferred TCS office location
- Solve the captcha and click on “Submit”
8. Receive a Reference ID
Once the form is submitted, you will receive a reference ID (e.g., DT1234567890). This is important for all future communication.
9. Fill Out the Application Form
Log into the dashboard and open the “Application Form” from the side menu. Fill it out carefully:
- Personal information
- Academic records (10th, 12th, graduation)
- Work experience (if applicable)
10. Submit the Application
Once all details are filled, click on the “Submit Application” button. Your registration is now complete.
11. Apply for the Drive
Lastly, go to the dashboard and click on “Apply for Drive”. Choose your preferred test centers and confirm your participation.
Important Tips:
- Always double-check your details before submission.
- Use a desktop or laptop for a smoother experience.
- Keep scanned copies of your documents ready.
- Save your Reference ID for future use.
Conclusion
Filling the TCS NQT form correctly can save you a lot of trouble down the line. With this detailed guide, you now have all the information needed to register smoothly. Stay focused, prepare well, and take your first step toward a successful career with TCS.
For a complete video walkthrough of this process, check out:
TCS NQT 2025 Full Registration Process | Step-by-Step Video Guide
Watch here: https://youtu.be/MOvOfJh26TI?si=Jvivgf5lzaerNuYc