I am new to neo4j can you please help to write a cypher query for the following subgraph. We are using neo4j.3.5.x version.
A--->next--->S1<----Has-----S
A--->.next---->S2<-----Has----S
B--->next--->T1<----Has-----T
B--->next--->T2<----Has-----T
B---...