0% found this document useful (0 votes)
2 views

TCS NQT Coding Questions

The document outlines various coding problems and algorithms relevant for TCS NQT preparation, including sorting algorithms, searching algorithms, array problems, number problems, number system problems, and string problems. It provides links to resources for further assistance and preparation. The content serves as a comprehensive guide for candidates preparing for coding interviews and assessments.

Uploaded by

jeevajeeva40348
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

TCS NQT Coding Questions

The document outlines various coding problems and algorithms relevant for TCS NQT preparation, including sorting algorithms, searching algorithms, array problems, number problems, number system problems, and string problems. It provides links to resources for further assistance and preparation. The content serves as a comprehensive guide for candidates preparing for coding interviews and assessments.

Uploaded by

jeevajeeva40348
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

TCS NQT Coding Ques Revision

Youtube Channel - https://www.youtube.com/@curiousfreaks_


To Get help from Nandhini to prepare for placements -
https://curiousfreakss.com/
Connect with me on LinkedIn -
https://www.linkedin.com/in/nandhini-raja-8b71b4143/

Sorting Algorithms
●​ Bubble Sort Algorithm
●​ Selection Sort Algorithm
●​ Insertion Sort Algorithm
●​ Quick Sort Algorithm
●​ Merge sort algorithm

Searching Alrogithms
●​ Linear Search
●​ Binary Search

Array Problems
●​ Find the smallest number in an array
●​ Find the largest number in an array
●​ Second Smallest and Second Largest element in an array
●​ Reverse a given array
●​ Count frequency of each element in an array
●​ Rearrange array in increasing-decreasing order
●​ Calculate sum of the elements of the array
●​ Rotate array by K elements - Block Swap Algorithm
●​ Average of all elements in an array
●​ Find the median of the given array
●​ Remove duplicates from a sorted array
●​ Remove duplicates from unsorted array
●​ Adding Element in an array
●​ Find all repeating elements in an array
●​ Find all non-repeating elements in an array
●​ Find all symmetric pairs in array
●​ Maximum sum in a subarray
●​ Maximum product subarray in an array
●​ Replace each element of the array by its rank in the array
●​ Sorting elements of an array by frequency
●​ Rotation of elements of array- left and right
●​ Finding equilibrium index of an array
●​ Finding Circular rotation of an array by K positions
●​ Sort an array according to the order defined by another array
●​ Search an element in an array
●​ Check if Array is a subset of another array or not

Problems on Numbers
●​ Check if a number is palindrome or not
●​ Find all Palindrome numbers in a given range
●​ Check if a number is prime or not
●​ Prime numbers in a given range
●​ Check if a number is armstrong number of not
●​ Check if a number is perfect number
●​ Even or Odd
●​ Check weather a given number is positive or negative
●​ Sum of first N natural numbers
●​ Find Sum of AP Series
●​ Program to find sum of GP Series
●​ Greatest of two numbers
●​ Greatest of three numbers
●​ Leap Year or not
●​ Reverse digits of a number
●​ Maximum and Minimum digit in a number
●​ Print Fibonacci upto Nth Term
●​ Factorial of a number
●​ Power of a number
●​ Factors of a given number
●​ Print all prime factors of the given number
●​ Check if a number is a strong number or not
●​ Check if a Number is Automorphic
●​ GCD of two numbers
●​ LCM of two numbers
●​ Check if a number is Harshad number
●​ Check if the number is abundant number or not
●​ Sum of digits of a number
●​ Sum of numbers in the given range
●​ Permutations in which N people can occupy R seats in a classroom
●​ Program to add two fractions
●​ Replace all 0s with 1s in a given integer
●​ Program to find roots of a Quadratic Equation
Problems on Number System
●​ Convert Binary to Decimal
●​ Convert binary to octal
●​ Decimal to Binary conversion
●​ Convert decimal to octal
●​ Convert octal to binary
●​ Convert octal to decimal
●​ Convert digits/numbers to words

Problems on String
●​ Check if a given string is palindrome or not
●​ Count number of vowels, consonants, spaces in String
●​ Find the ASCII value of a character
●​ Remove all vowels from the string
●​ Remove spaces from a string
●​ Remove characters from a string except alphabets
●​ Reverse a String
●​ Remove brackets from an algebraic expression
●​ Sum of the numbers in a String
●​ Capitalize first and last character of each word
●​ Calculate frequency of characters in a string
●​ Find Non-repeating characters of a String
●​ Check if two strings are anagram of each other
●​ Count common sub-sequence in two strings
●​ Check if two strings match where one string contains wildcard characters
●​ Return maximum occurring character in the input string
●​ Remove all duplicates from the input string.
●​ Print all the duplicates in the input string.
●​ Remove characters from first string present in the second string
●​ Change every letter with the next lexicographic alphabet in the given string
●​ Write a program to find the largest word in a given string.
●​ Write a program to sort characters in a string
●​ Count number of words in a given string
●​ Write a program to find a word in a given string which has the highest number of
repeated letters
●​ Change case of each character in a string
●​ Concatenate one string to another
●​ Write a program to find a substring within a string. If found display its starting position
●​ Reverse words in a string

Note: Google search this problem, you can get the link in geeksforgeeks and leetcode.

You might also like