All company sheets
Cognizant logo

Cognizant DSA interview questions

27 problems to practise before your Cognizant online test or coding round. Most widely asked first.

27
Questions
11
Easy
16
Medium
0
Hard

Good practice. Problems at the level of this company’s online test and coding round. Treat it as a practice set, not a leak. These are Astra’s own tags, not an official question list.

Cognizant is hiring · 21 open roles on Astra right nowView roles

27 questions

  1. 1

    Find the Peak Index in a Mountain Array

    EasyBinary SearchTagged at 7 companies
  2. 2

    Move All Zeroes to the End of an Array In-Place

    EasyArrayTagged at 7 companies
  3. 3

    Increment a Large Integer Represented as an Array

    EasyArrayTagged at 7 companies
  4. 4

    Garbage Collection Memory Compaction

    EasyTwo PointersTagged at 7 companies
  5. 5

    Collaborative Text Editor Resolution

    EasyTwo PointersTagged at 7 companies
  6. 6

    Remove Duplicates from Sorted Array

    EasyTwo PointersTagged at 7 companies
  7. 7

    Squares of a Sorted Array

    EasyTwo PointersTagged at 7 companies
  8. 8

    Generate All Permutations II (With Duplicates)

    MediumRecursionTagged at 7 companies
  9. 9

    Search in a Rotated Sorted Array

    MediumRecursionTagged at 7 companies
  10. 10

    Merge Overlapping User Accounts (Accounts Merge)

    MediumRecursionTagged at 7 companies
  11. 11

    Find the K-th Largest Element in an Array (Quickselect)

    MediumArrayTagged at 7 companies
  12. 12

    Valid Anagram

    EasyStringTagged at 6 companies
  13. 13

    Check if Two Strings are Valid Anagrams

    EasyStringTagged at 6 companies
  14. 14

    Check if a String is a Valid Palindrome

    EasyStringTagged at 6 companies
  15. 15

    Remove All Adjacent Duplicates in a String

    EasyStringTagged at 6 companies
  16. 16

    Palindromic Substrings

    MediumStringTagged at 6 companies
  17. 17

    Remove K Digits from a Number to Make Smallest

    MediumStack and QueueTagged at 6 companies
  18. 18

    Add One to a Number Represented by Linked List

    MediumLinkedListTagged at 6 companies
  19. 19

    Delete a Node in a Linked List with O(1) Time Complexity

    MediumLinkedListTagged at 6 companies
  20. 20

    Find the Kth Largest Element in an Array (Heap)

    MediumTreeTagged at 6 companies
  21. 21

    Convert a Binary Search Tree to a Greater Sum Tree

    MediumTreeTagged at 6 companies
  22. 22

    Find the Maximum Width of a Binary Tree

    MediumTreeTagged at 6 companies
  23. 23

    Find the Number of Connected Components in a Graph

    MediumTreeTagged at 6 companies
  24. 24

    Implement String to Integer (atoi)

    MediumStringTagged at 6 companies
  25. 25

    Implement Zigzag Conversion for a String

    MediumStringTagged at 6 companies
  26. 26

    Multiply Two Large Numbers Represented as Strings

    MediumStringTagged at 6 companies
  27. 27

    Find the Longest Substring with At Most K Distinct Characters

    MediumStringTagged at 6 companies

More company sheets