# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
837832 | Liudas | Type Printer (IOI08_printer) | C++17 | 66 ms | 39752 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
#define endl "\n"
using namespace std;
const int MAX_SIZE = 26;
struct node{
node *arr[MAX_SIZE];
char val;
int end;
int maxi;
};
node *getNode(){
node *nnode = new node;
nnode -> end = 0;
nnode -> maxi = 0;
for(int i = 0; i < MAX_SIZE; i ++){
nnode -> arr[i] = NULL;
}
return nnode;
}
void insert_node(node *root, string s){
node *cur = root;
for(char i : s){
int id = i - 'a';
if(!cur -> arr[id]){
cur ->arr[id] = getNode();
}
cur = cur -> arr[id];
}
cur -> end ++;
cur -> maxi = 1;
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |