Topic: Stack Problem / Level: advanced

Problem: Write a stack-based solution for solving the problem of finding the longest subsequence of alternating positive and negative numbers in an array.

Run the code to see the output here...