Think You’re Ready for TCS NQT? Solve These 15 Questions First

TCS NQT

1. Write a program to check wheather a number is prime or not?

C++
Java
Python
JavaScript


2. Write a program to find Factorial of a Number

C++
Java
Python
JavaScript


3. Write a program to check a Number is Even or Odd

C++
Java
Python
JavaScript


4. Write a program to calculate the sum of all digits of a given integer.

C++
Java
Python
JavaScript


5. Write a program to reverse the digits of a given integer.

C++
Java
Python
JavaScript


6. Write a program to check whether a given integer is a Palindrome or not.

C++
Java
Python
JavaScript


7. Write a program to check whether a given number is an Armstrong Number or not.

C++
Java
Python
JavaScript


8. Write a program to find the largest among three given numbers.

C++
Java
Python
JavaScript


9. Write a program to calculate the GCD (Greatest Common Divisor) and LCM (Least Common Multiple) of two given integers.

C++
Java
Python
JavaScript


10. Write a program to check whether a given year is a Leap Year or not.

C++
Java
Python
JavaScript


11. Move All Zeros to the End (Chocolate Packets Problem)

C++
Java
Python
JavaScript


12. Toggle Bits After MSB (Decimal to Binary)

C++
Java
Python
JavaScript


13. Write a program to count the number of vowels and consonants in a given string.

C++
Java
Python
JavaScript


14. Write a program to check whether two given strings are Anagrams of each other.

C++
Java
Python
JavaScript


15. Write a program to remove duplicate characters from a given string while maintaining the original order of characters.

C++
Java
Python
JavaScript


Conclusion

Stay Ahead in Your Tech Career 🚀

We don’t spam! Read our privacy policy for more info.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top