You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For "number of substrings", instead of doing DP over the DAG structure, I think we just have to add up len(u) - len(link(u)) (which is # of strings in the state) over all non-root state u. Similar for "total length of all different substrings" as well.