I am looking for building logic in Java for screen flow consolidation. Sample for input and output is below. Can you please suggest what data structure fits best for this scenario.
I was able to build a logic to count screen watch at each level but still thinking over how to come to exact desirable output. Any idea would be appreciated.
Screen1,2 -> Screen2,2 -> Screen3,2 -> Screen4,4
Screen3,3 -> Screen4,3 -> Screen5,3 -> Screen8,3
Screen9,2, -> Screen2,1 -> Screen3,1 -> Screen9,1 -> Screen10,1
Screen9,1, -> Screen10,1 -> Screen11,1 -> Screen12