🔵 IBM OA – Application Developer (Experience Front End) | Questions I Got
Anonymous User
770

Just completed the IBM Online Assessment for the Application Developer – Experience Front End role.
Sharing the coding questions for anyone preparing.

Platform: HackerRank
Questions: 2 Coding
Difficulty: Easy–Medium
Focus Areas: Sliding Window, Hashing, Subarrays / Substrings


🔹 Question 1: Count Subarrays With Product = K

Problem (High-level):
Given an integer array nums and an integer k, return the total number of contiguous subarrays whose product of elements equals k.

  • Subarrays may overlap
  • Order matters (contiguous only)

Example

nums = [2, 3, 2, 2]
k = 4

Output: 1
Explanation:
Only subarray [2, 2] has product = 4

Key Observations

  • Brute-force O(n²) works for small input but may TLE
  • Since numbers are positive, sliding window / prefix-product logic helps
  • Need to be careful with product overflow and resets

What This Tests

  • Subarray enumeration logic
  • Edge cases with multiplication
  • Optimization thinking

🔹 Question 2: Count Substrings With All Unique Characters

Problem (High-level):
Given a string text, count the number of substrings that contain only distinct characters.

Two substrings are different if they start or end at different positions.

Example

text = "abac"
Output: 8

Valid substrings:
"a", "b", "a", "c", "ab", "ba", "ac", "bac"

Constraints

  • 1 ≤ |text| ≤ 10^5
  • Only lowercase English letters

Key Observations

  • Classic sliding window + frequency map problem
  • Maintain a window with no repeating characters
  • For each right pointer, count valid substrings ending at that index

What This Tests

  • Sliding window mastery
  • Hashing / frequency tracking
  • Efficient counting logic

🧠 Overall Experience

  • Questions were straightforward but required clean logic

  • Emphasis was on:

    • Writing efficient solutions
    • Handling edge cases
    • Understanding problem constraints
  • Very doable with solid DSA fundamentals


📌 Preparation Tips for IBM OA

  • Practice:

    • Sliding window problems
    • Subarray vs substring differences
    • Frequency map techniques
  • Focus on clean code + correctness

  • Don’t overthink — problems are mostly pattern-based


✅ Final Thoughts

IBM OA felt fair and practical, especially for a Front End–aligned role with strong algorithmic basics.

If anyone else appeared recently and got different questions, feel free to comment and share 👇
All the best to everyone preparing! 🚀

Comments (2)