Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

DSA Top 20 Questions Asked by Coding Round in Sony Company.

1. Write a program to reverse a given string.

2. Write a program to find the largest and smallest number in a given array.

3. Write a program to find the maximum and minimum of two numbers without using if-else
or any other comparison operator.

4. Write a program to check whether a given number is palindrome or not.

5. Write a program to print all the prime numbers between 1 to n.

6. Write a program to find the sum of all the elements of an array.

7. Write a program to sort an array of integers using the QuickSort algorithm.

8. Write a program to implement a binary search algorithm.

9. Write a program to print the Fibonacci sequence up to a given number.

10. Write a program to check whether a given string is a palindrome or not.


11. Write a program to find the maximum and minimum of three numbers without using if-
else or any other comparison operator.

12. Write a program to find the GCD of two numbers using the Euclidean algorithm.

13. Write a program to implement the Bubble Sort algorithm.

14. Write a program to convert a given number from decimal to binary.

15. Write a program to generate all possible combinations of a given string.

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

17. Write a program to convert a given number from binary to decimal.

18. Write a program to find the sum of all the multiples of 3 or 5 below 1000.

19. Write a program to find the kth smallest element in an unsorted array.

20. Write a program to generate all the permutations of a given string.

Solution will provide our Telegram Channel

Telegram Channel :- https://telegram.me/NxtEngineerJoin our community :-


https://chat.whatsapp.com/JS33SUB05l51PrG9YoKNAV

You might also like