[go: up one dir, main page]

0% found this document useful (0 votes)
61 views2 pages

Coding_Questions_Service_Companies

This document provides a list of over 50 essential array and string coding questions commonly asked in placement rounds for service-based companies like TCS, Infosys, and Wipro. It includes important topics related to array manipulation, sorting techniques, and string operations. The questions cover a range of skills necessary for coding interviews, including algorithms and data structure concepts.
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)
61 views2 pages

Coding_Questions_Service_Companies

This document provides a list of over 50 essential array and string coding questions commonly asked in placement rounds for service-based companies like TCS, Infosys, and Wipro. It includes important topics related to array manipulation, sorting techniques, and string operations. The questions cover a range of skills necessary for coding interviews, including algorithms and data structure concepts.
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/ 2

Service-Based Companies Coding Round - Must Practice Questions

This PDF contains a curated list of 50+ most frequently asked and important array and string

questions for service-based company placement rounds (TCS, Infosys, Wipro, Capgemini,

Accenture).

Array Questions
1. Find the maximum and minimum element in an array
2. Find the second largest and second smallest elements
3. Reverse the array
4. Sort an array of 0s, 1s, and 2s
5. Find the missing number in an array from 1 to n
6. Find duplicate elements in an array
7. Move all zeroes to end of array
8. Check if array is sorted
9. Count frequency of each element
10. Find the number that appears once while others appear twice
11. Find leaders in an array
12. Maximum difference between two elements such that larger appears after smaller
13. Subarray with given sum (Sliding Window)
14. Kadanes algorithm - Maximum subarray sum
15. Merge two sorted arrays
16. Union and Intersection of two arrays
17. Left rotate the array by D places
18. Count pairs with given sum
19. Find equilibrium index
20. Rearrange array in alternating positive and negative items

String Questions
21. Check if a string is a palindrome
22. Reverse a string
23. Reverse words in a given string
24. Check if two strings are anagrams
25. Count vowels and consonants in a string
26. Remove duplicate characters from a string
27. Check if a string contains only digits
28. Check if two strings are rotations of each other
29. Find first non-repeating character
30. Longest common prefix among array of strings
31. Implement strstr() (substring match)
32. Count words in a string
33. Print all substrings of a string
34. Check for balanced parentheses
35. Change case of characters in string
36. Find duplicate characters in string
37. Check if characters of one string are present in another
38. Find the most frequent character in a string
39. Compress the string (basic run length encoding)
40. Remove spaces from a string

Important Topics
Important Array Topics:
- Array Traversal and Manipulation
- Sorting Techniques (Bubble, Insertion, etc.)
- Prefix Sum and Sliding Window
- Frequency Hashing (using maps or arrays)
- Two Pointer Technique
- Searching (Linear/Binary)

Important String Topics:


- String Traversal and Manipulation
- Character Frequency using Hashmaps
- Palindrome Logic
- Anagram Check
- Pattern Matching Basics (strstr, contains, etc.)
- Balanced Brackets (Stack basics)

You might also like