← Microsoft questions

Longest Palindromic Substring and Spiral Matrix Traversal

Filed under Microsoft

You are given two distinct tasks: first, find the longest palindromic substring in a given string; second, traverse a 2D matrix in spiral order and return the elements as a list.

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Microsoft questions

Collected from public candidate posts and coding forums. Updated Nov 2026.