- 0
Notifications Mark All Read
- Login
- Get Prime
TCS NQT Menu
- Placement Papers
- What is TCS NQT?
- How To Apply
- Foundation Section
- Aptitude Questions
- English Verbal
- Reasoning Ability
- Advanced Section
- Advanced Quantitative Ability
- Advanced Reasoning Ability
- Advanced Coding
- Coding Questions
- Syllabus 2024
- Recruitment Process
- Registration Process
- Eligibility Criteria
- How to prepare for TCS NQT?
- Interview Questions
- Hiring Process
What kind of coding questions may be asked in TCS NQT 2021
What kind of Coding Question may be Asked in TCS NQT?
You must be wondering What kind of Coding Question may be asked in TCS NQT? as the time limit is increased? Here you go with all your answer. TCS NQT has updated its hiring pattern and has added some new sections. In the new pattern NQT, the exam has a different section specially dedicated to the coding section.
There will be no negative marking in the test and the test is partially adaptive. This round will have 2 sections.
Section | No. of questions | Time | Difficulty Level |
---|---|---|---|
Programming Logic | 10 | 15 mins | High |
Hands-on Coding | 2 | 15 mins and 30 mins | High |
What kind of Coding Question may be Asked in TCS NQT 2021?
Programming MCQ:
This round will have 10 questions that need to be answered in 15 minutes. The questions in this round will be the MCQ type of questions. The questions will be asked from the fundamentals of coding, input-output questions, etc.
The important topics in this section are: Functions, Arrays, Recursion, Linked List, Stacks, and Queues, etc.
This time TCS has allowed 4 languages and you can code in any language of your choice. You can switch languages for different questions. The languages allowed are:
- C
- C++
- Java
- Python
Hands-on Coding:
This section will have 2 questions. Question 1 needs to be answered in 15 minutes and question 2 in 30 minutes. In this round, you will be given statement questions and you need to write the code.
You can code in any language of your choice from C, C++, Java, Python
This is the most important section of the whole test. Even if you clear the first 4 rounds with 100% you still need to clear this round, otherwise, you won’t be able to qualify this round.
To clear this round, your code should run end to end and pass all the test cases.
Let’s take a sample question.
Ques- Write a program to find the Fibonacci series up to n terms.
Solution: In C
#include<stdio.h> int main() { //To initialize variables int n1=0,n2=1,n3,limit,i; //To take user input printf("enter a limit of series \n"); scanf( "%d",&limit); printf("Fibonacci series %d %d ",n1,n2); //To use this loop for given length for(i=2;i<limit;i++) { //n1 and n2 sum store in new variable n3 n3=n1+n2; n1=n2; n2=n3; //display serious printf("%d ",n3); } return 0; }
Ques: Check whether the number is automorphic or not.
Solution: In Java.
import java.util.Scanner; public class automorphic_number_or_not { public static void main(String[] args) { //scanner class declaration Scanner sc = new Scanner(System.in); //input from user System.out.print("Enter a number : "); int number = sc.nextInt(); //Convert the number to string String s1 = Integer.toString(number); //Calculate the length int l1 = s1.length(); int sq = number * number; String s2 = Integer.toString(sq); int l2 = s2.length(); //Create Substring String s3 = s2.substring(l2-l1); if(s1.equals(s3)) System.out.println("Automorphic Number"); else System.out.println("Not an Automorphic Number"); //closing scanner class(not compulsory, but good practice) sc.close(); } }
To practice more such questions in all the levels and know the top 100 codes that may be asked in TCS NQT. Click the button below.
TCS expects graduates to know how to code as it gets many projects in which they need website development, etc and therefore they check the coding skills before hiring.
They take the coding test to see how much you are familiar with the coding languages. You need to know the basics of coding to crack the exam and then they will train you in the training period.
Login/Signup to comment