MCPcopy Create free account
hub / github.com/Jonathan-Uy/CSES-Solutions / main

Function main

String Algorithms/Substring Order I.cpp:74–88  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

72}
73
74int main(){
75 scanf(" %s %lld", S, &K);
76 N = (int) strlen(S);
77
78 init();
79 for(int i = 0; i < N; i++)
80 extend(S[i]);
81 calc();
82
83 dfs(0, K-1);
84 int M = (int) ans.size();
85 for(int i = 0; i < M; i++)
86 printf("%c", ans[i]);
87 printf("\n");
88}

Callers

nothing calls this directly

Calls 4

initFunction · 0.70
extendFunction · 0.70
calcFunction · 0.70
dfsFunction · 0.70

Tested by

no test coverage detected