[
  {
    "path": ".gitignore",
    "content": ""
  },
  {
    "path": "CODE_OF_CONDUCT.md",
    "content": "# Código de Conduta\n\nA UBL é um ambiente onde todos os que aprendem e contribuem podem se sentir seguros e acolhidos. Este documento define as políticas e valores da nossa comunidade.\n# Regras\n* Aprenda e ajude os outros a aprenderem.\n* Seja gentil e educado com os seus colegas.\n* Critique ideias, não pessoas.\n* Discuta de forma pública. Evite mandar mensagens diretas para as pessoas, a menos que elas peçam.\n* Faça perguntas; não pergunte se pode perguntar. Não precisa escrever \"Tem alguém que pode me ajudar com X?\" Simplesmente pergunte sobre X.\n# Proibições\n* Nenhuma violência ou ameaça de violência de qualquer tipo.\n* Nenhuma linguagem ou ação sexista, racista, homofóbica, transfóbica, ou qualquer outra que seja preconceituosa ou discriminatória; isso inclui piadas.\n* Nenhum assédio sexual, incluindo avanços sexuais indesejados ou comentários ofensivos sobre o sexo de alguém.\n* Nenhum palavrão ou xingamento contra outras pessoas (mas pode usar palavrões e xingamentos sobre o código, IDE, linguagem, hardware ou física).\n* Nenhum material impróprio para menores. Isso inclui nudez, gore, ou qualquer outra imagem que possa ser perturbadora.\n* Nenhuma divulgação de informações privadas de outra pessoa sem a sua permissão (doxxing).\n* Nenhum assédio ou intimidação, online ou fora da internet.\n* Nenhum spam, trollagem, provocação, ou qualquer outra coisa que atrapalhe a paz.\n* Nenhum nome de usuário inadequado. Os moderadores irão mudar o seu nome se ele for considerado impróprio para menores ou ofensivo.\n* Nenhuma defesa ou ameaça de qualquer um dos comportamentos proibidos.\n# Denúncia e Moderação\nNo servidor da UBL no Discord, os usuários podem usar @Moderação e @Admin para alertar a equipe de moderação sobre algum problema em um canal.\n\nNo GitHub você pode nos marcar diretamente em qualquer issue ou PR sobre uma violação.\n\nSe você vir algum comportamento que viole o Código de Conduta, denuncie-o à equipe de moderação o mais rápido possível, seja de forma privada ou pública.\n\nA violação dos termos deste Código de Conduta terá consequências que dependerão de a) a gravidade da violação, e b) o histórico de violações. As possíveis consequências são: silenciamento temporário, expulsão da participação, banimento temporário ou permanente de toda a participação futura na comunidade.\n\nSe você se sentir injustiçado, você pode contatar um moderador ou organizador da comunidade e explicar o seu problema. O seu problema será resolvido por consenso dos moderadores.\n\n# Atribuição\nPartes deste Código de Conduta foram inspiradas pelos seguintes:\n* [Contributor Covenant](https://www.contributor-covenant.org/version/2/0/code_of_conduct/)\n* [Rust Lang Code of Conduct](https://www.contributor-covenant.org/version/2/0/code_of_conduct/)\n* O Código de Conduta do OSSU, derivado do [Código de Conduta do Fórum FrontEnd BR](https://www.contributor-covenant.org/version/2/0/code_of_conduct/)\n"
  },
  {
    "path": "LICENSE",
    "content": "MIT License\n\nCopyright (c) 2023 Universidade Brasileira Livre\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n"
  },
  {
    "path": "README.md",
    "content": "![Rinha de Algoritmos](./resources/img/header_2024.png)\n\n<p align=\"center\">\n  <a href=\"https://discord.gg/eXUBTY6HAu\">\n      <img src=\"https://img.shields.io/discord/866378348368625704.svg?label=&logo=discord&logoColor=ffffff&color=7389D8&labelColor=6A7EC2\" alt=\"Discord\">\n  </a>\n  <a href=\"https://github.com/Universidade-Livre/rinha-de-algoritmos/stargazers\">\n      <img alt=\"GitHub Repo stars\" src=\"https://img.shields.io/github/stars/Universidade-Livre/rinha-de-algoritmos?logo=apache%20spark&logoColor=gray&labelColor=E6E600&color=D8D800\">\n  </a>\n</p>\n\n<hr>\n\n> Você está prestes a entrar na Rinha de Algoritmos, uma competição incrível que desafia você a mostrar o seu talento no mundo dos algoritmos e estruturas de dados. Nesta aventura, você vai enfrentar problemas reais que exigem soluções criativas e eficientes. Você vai se surpreender com casos curiosos, onde a sua habilidade em resolver desafios computacionais fará toda a diferença. Prepare-se para se divertir em um ambiente estimulante, onde o seu domínio algorítmico será testado. Venha para a Rinha de Algoritmos e embarque nessa jornada desafiadora!\n\n## O que é?\n\nA rinha de algoritmos é uma competição amistosa baseada em competições similares, como a [Rinha de Compiladores](https://github.com/aripiprazole/rinha-de-compiler), [Rinha de Frontend](https://github.com/codante-io/rinha-frontend), e [Rinha de Backend](https://github.com/zanfranceschi/rinha-de-backend-2023-q3). O projeto possui como objetivo avaliar a capacidade dos participantes no design de algoritmos e estruturas de dados para resolver problemas práticos.\n\nPara avaliar os participantes, a descrição de algum caso prático será proposta. Caberá aos participantes identificar o problema e propor a melhor solução para resolvê-lo. Seguindo o mesmo modelo de maratonas de programação, serão fornecidas uma lista de entradas e de resultados esperados, em formato de texto, que poderão ser utilizados para guiar a criação do algoritmo. A pontuação e o ranking correspondente serão baseados em instâncias privadas que serão liberadas **apenas ao final** da competição.\n\nCada participante deverá entregar um algoritmo, sinalizando para qual problema aquele algoritmo foi criado, podendo utilizar apenas 2 unidades de CPU e 2GB de memória. Para mais detalhes sobre as submissões, veja [como submeter um algoritmo](how_to_participate.md).\n\nCaso hajam dúvidas, por favor abram uma *issue* ou utilizem o nosso servidor do Discord!\n\n## Regras\n\n- Embora estaremos sempre incentivando a conversa e colaboração entre os participantes em prol do estabelecimento de um ambiente de aprendizado, não será permitido compartilhar as soluções nos canais de comunicação da UBL¹;\n\n- Para essa competição é importante ressaltar que **não** é permitido o uso de *solvers*².  \n\n- Caso sejam utilizados algoritmos de Monte Carlo³, o valor de solução a ser considerado será o melhor dentre $40$ iterações do algoritmo, ou o valor mais próximo possível dessa quantidade de iterações, a depender do tempo necessário para uma solução ser computada.\n\n---\n\n> ¹: *Note que isso não proibe tirar dúvidas de outros participantes ou fornecer direções. Não esperamos que cada candidato submeta uma solução única, até mesmo porque uma implementação inteligente pode fazer a diferença entre ambas as submissões.*\n>\n> ²: *Um solver é um programa de computador que, quando aplicado a um problema, é capaz de encontrar a solução automaticamente, sem intervenção direta ou ajuste significativo por parte do usuário. Geralmente, o objetivo de um solver é encontrar a melhor solução ou uma solução aproximada para o problema, tornando-o um mecanismo automatizado de resolução. Na Rinha de Algoritmos, seu uso é proibido. A justificativa é incentivar a resolução manual e criativa dos problemas.*\n> \n> ³: *Aos participantes interessados em aprender mais sobre algoritmos probabilisticos, vejam os livros recomendados para a Rinha e a página na [Wikipedia](https://en.wikipedia.org/wiki/Randomized_algorithm).*\n\n---\n\n## Pontuação\n\nUma função $f: \\mathbb{R}^2 \\rightarrow \\mathbb{R}$ determinará a pontuação dos participantes. Antes de descrevê-la, denotaremos por $\\mathbf{x} = [x_1 \\; x_2]^T$ o vetor de saída do algoritmo, onde $x_1$ é o tempo, em segundos, para obtenção da solução, e $x_2$ é o valor da **solução viável**¹ encontrada.\n\nA pontuação é dada por $f(\\mathbf{x}) = \\min(100, \\; C_{1} / x_{1}) + \\min(100, \\; C_{2} / |x^{\\star} - x_{2}|)$, onde $x^{\\star}$ é o valor da solução ótima. As constantes $C_1$ e $C_2$ serão definidas para cada problema, e servem para penalizar o tempo de execução e o quão distante a solução viável está do ótimo, respectivamente.\n\nVale ressaltar que quanto maior for o valor de $f(\\mathbf{x})$, melhor será a pontuação.\n\n---\n\n> ¹: *Uma solução viável é toda solução que satisfazem as restrições do problema, embora talvez não seja a solução ótima.*\n\n---\n\n## Problemas\n\n### Problema 01: Lucro de Plantação no Stardew Valley\n\n**Descrição:** Na busca por otimizar seus ganhos enquanto joga Stardew Valley, você analisa as opções de sementes disponíveis em determinado momento e registra a quantidade de espaços disponíveis para o plantio. \n\nPor ser um fazendeiro organizado, você já tem conhecimento sobre a quantia de moedas que pode obter ao plantar cada tipo de semente durante um período específico, bem como a quantidade de espaços necessários para cada uma delas. Seu objetivo é, portanto, maximizar seu lucro ao plantar o maior número possível de sementes, levando em consideração a capacidade de plantio disponível, ao final do período escolhido. Para fins de simplicidade, assumiremos que todas as sementes possuem o mesmo tempo de plantio e maturação.\n\nPara este problema, definiremos $C_{1} = 1$, $C_{2} = 0.2$, e uma pontuação bônus por cada instância resolvida de $C_{3} = 50$.\n\nConfira os detalhes em [como participar](how_to_participate.md#problema-01).\n\n---\n\n### Problema 02: Age of Empires - A Grande Fronteira\n\n**Descrição:** Na vastidão estratégica do Age of Empires, o participante ousa enfrentar o desafio supremo denominado \"A Grande Fronteira\". Neste épico, os líderes imperiais, incluindo você, são convocados a traçar uma trama intrincada de postos avançados não apenas para expandir os domínios do império, mas para construir uma defesa intransponível contra os astutos adversários.\n\nEsses postos avançados, transcendendo meras construções, tornam-se os pilares cruciais na busca pela supremacia. A singularidade deste desafio coloca você na posição de escolher sabiamente os locais estratégicos, onde os postos avançados devem dominar as extremidades da fronteira, enquanto mantêm uma rede complexa que conecta todas as propriedades do império. O objetivo é criar uma teia que, ao expandir territorialmente, posiciona os postos avançados como sentinelas estratégicas, maximizando a muralha defensiva.\n\nA vitória não está apenas na quantidade de território conquistado, mas na maestria de suas escolhas, destacando-se em \"A Grande Fronteira\". Como líder imperial, ao assegurar a máxima presença defensiva e conectar todas as propriedades do vasto império, você gravará seu nome na história estratégica do Age of Empires. Que a sua sagacidade e estratégia iluminem o caminho para a supremacia!\n\nPara este problema problema, definiremos $C_{1} = 100$, $C_{2} = 25$, e uma pontuação bônus para cada instância resolvida de $C_{3} = 70$.\n\n---\n\n### Problema 03: ???\n\n**Descrição:** ???\n\n## Resultados\n\nNesta seção disponibilizaremos os resultados das submissões. Para cada instância resolvida, uma pontuação bônus será aplicada. \n\nIncluiremos uma submissão secreta de um membro da moderação da UBL para fins de benchmarking inicial. Esta submissão **não** será considerada para fins de premiação.\n\nA pontuação será calculada a partir da média de $40$ iterações do algoritmo.\n\n---\n### Resultados do Problema 01:\n\n| Posição | Participante | Segundos | Resolvidas | Linguagem\n| ---------- | ---------- | ------- | ------- | ---------- |\n| - | Secreto | ? | ?/20 | ? |\n---\n\n### Resultados do Problema 02:\n\n| Posição | Participante | Pontuação | Resolvidas | Linguagem\n| ---------- | ---------- | ------- | ------- | ---------- |\n| - | Secreto | ? | ?/20 | ? |\n\n---\n\n### Resultados do Problema 03:\n\n| Posição | Participante | Pontuação | Resolvidas | Linguagem\n| ---------- | ---------- | ------- | ------- | ---------- |\n| - | Secreto | ? | ?/20 | ? |\n\n---\n\n\n## Premiação\n\nForneceremos uma premiação simbólica para os três primeiros colocados. Esta premiação consiste em cargos comemorativos no [servidor da UBL](url).\n\n## Leitura recomendada\n\nNesta seção incluiremos alguns livros recomendados que podem ajudar na elaboração de algoritmos para os problemas que serão trabalhados nesta Rinha. Quando gratuitos, incluiremos um link para acesso.\n\nNão faremos a distinção entre um livro de nível básico ou avançado. Cabe ao participante conferir as primeiras páginas do livro e fazer esse juízo por si só.\n\n### Referências\n\n- Carvalho, Cerioli, Dahab, Feofiloff, Fernandes, Ferreira, Guimarães, Miyazawa, Pina Jr, Soares, Wakabayashi, Uma Introdução Sucinta a Algoritmos de Aproximação, IMPA, 2001. [Disponivel aqui](https://www.ime.usp.br/~cris/aprox/).\n\n- Cormen, T. H., Leiserson, C. E., Rivest, R. L., & Stein, C. (2009). Introduction to Algorithms (3rd ed.). London, England: MIT Press.\n\n- J.L. Szwarcfiter e L. Markenzon,  Estruturas de Dados e seus Algoritmos, 2a.ed., Livros Técnicos e Científicos, 1994.\n\n- Kleinberg, J., & Tardos, E. (2006). Algorithm design. Pearson Education India.\n\n- Mitzenmacher, M., & Upfal, E. (2017). Probability and computing (2nd ed.). Cambridge, England: Cambridge University Press.\n\n- Motwani, R., & Raghavan, P. (1995). Randomized algorithms. Cambridge University Press. \n\n- P. Feofiloff, Y. Kohayakawa, & Y. Wakabayashi. (2011). Uma Introdução Sucinta à Teoria dos Grafos. [Disponível aqui](https://www.ime.usp.br/~pf/teoriadosgrafos/).\n\n- P. Feofiloff. Análise de Algoritmos. [Disponível aqui](https://www.ime.usp.br/~pf/analise_de_algoritmos/).\n\n- P. Feofiloff. (2019). Minicurso de Análise de Algoritmos. [Disponível aqui](https://www.ime.usp.br/~pf/livrinho-AA/).\n\n- Vazirani, V. V. (2002). Approximation algorithms. Springer Science & Business Media.\n"
  },
  {
    "path": "how_to_participate.md",
    "content": "# Como participar\n\nNesta seção descreveremos os procedimentos para participação e submissão na Rinha de Algoritmos.\n\n## Como submeter\n\nComeçar a Rinha de Algoritmos é mamão com açúcar, é só:\n\n1. No seu Terminal, clone esse repositório com o comando `git clone git@github.com:Universidade-Livre/rinha-de-algoritmos`.\n2. Crie uma ramificação (branch) no repositório clonado para a resolução do seu exercício com o comando `git checkout -b problema-1`.\n3. Na pasta [submissions](./submissions/) crie uma pasta com o seu nome de usuário. Ex: `mateusrovedaa/`\n4. Resolva o problema com base nas instruções informadas na seção [Instâncias](#instâncias) e salve o código em um arquivo com o nome `problema-1.ext`, onde `ext` é a extensão da linguagem de programação. Além disso, crie um arquivo `README.md` colocando instruções e detalhes da implementação que achar necessário. Preferencialmente, faça com que o seu código receba o arquivo das instâncias como argumentos no CLI.\n5. Ainda, para facilitar a avaliação por parte da organização, crie um ambiente Docker limitando os recursos para duas unidades de CPU e 2GB de RAM, conforme as restrições mencionadas no [README](README.md). \n6. Adicione as alterações feitas para serem enviadas com o comando `git add .`\n7. Faça o commit enviando essas alterações `git commit -m \"Submissão do problema 01\"`.\n8. Abra um PR para a ramificação main.\n\n## Instâncias\n\nPara cada problema fornecemos 3 instâncias relativamente pequenas para realizar os experimentos iniciais. As instâncias referentes ao problema $1 \\leq i \\leq 3$ encontram-se em `resources/instancias/exemplo_0i`. Ainda, todas as pastas contêm um arquivo `resultados.txt` com as soluções ótimas das instâncias dadas, separadas por espaço.\n\nNas seções abaixo, descreveremos a estrutura dos arquivos de texto que compõem as instâncias e formalizaremos os objetivos e restrições.\n\n## Estrutura dos Problemas\n\n### Problema 01\n\n**Entrada:**\n\nSeja $n$ a quantidade de sementes, $v_{i}$ e $w_{i}$ o valor e a quantidade de espaços necesários para a semente $i$, e $W$ a quantidade de espaços disponíveis. O problema possui os seguintes limitantes. As instâncias estão organizadas da seguinte maneira.\n\n- A primeira linha consiste de dois valores, a quantidade de sementes distintas e a quantidade de espaços disponíveis, respectivamente.\n\n- As $n$ linhas seguintes, onde $n$ é a quantidade de tipos sementes, consistem de dois valores por linha, divididas por espaço. O primeiro é o espaço necessário $w_{i}$ para plantar a semente $i$, já o segundo corresponde ao ganho em moedas $v_{i}$ no final do periodo ao plantar esta semente.\n\nPara todos os tipos de semente, você possui apenas **UMA** unidade!\n\n**Limites:**\n\n- $1 \\leq n \\leq 1000$\n- $30 \\leq v_{i} \\leq 200$\n- $1 \\leq w_{i} \\leq 7$\n- $1 \\leq W \\leq 2666$\n\n**Objetivo:** \n\n- Obtenha o lucro máximo possível.\n\n**Exemplo**\n\nSuponhamos que você receba as informações abaixo, e que possui apenas 2 blocos disponíveis pra plantio.\n\n| **Semente** | **Valor** | **Espaço** |\n|-------------|-----------|------------|\n| Café        | 150       | 1          |\n| Arroz       | 260       | 2          |\n| Cenoura     | 100       | 1          |\n\nPodemos ver facilmente que a solução ótima é dada pelo plantio de arroz apenas. Perceba que o plantio de duas unidades de café, totalizando um lucro de 300, não é possível pela nossa suposição de haver apenas uma única unidade de cada tipo de semente.\n\n---\n\n### Problema 02\n\n**Entrada:**\n- A primeira linha contém dois inteiros: o número de postos avançados $N$ ($2 \\leq N \\leq 120$) e o número de estradas $M$ ($1 \\leq M \\leq \\frac{N \\times (N-1)}{2}$).\n- As próximas $M$ linhas contêm dois inteiros cada: $u$ e $v$ ($1 \\leq u, v \\leq N$), indicando uma estrada conectando os postos avançados $u$ e $v$.\n\n**Saída:**\n- A saída deve conter um único inteiro $K$: o número total de postos avançados que definem a muralha\n\n**Objetivo:**\n- Maximizar o tamanho da muralha, definida como quantidade de pontos avançados nas extremidades do território, enquanto conecta todas as propriedades do império.\n\n**Exemplo de Entrada 01:**\n\n```plaintext\n8 7\n1 2\n2 3\n3 4\n4 5\n5 6\n6 7\n7 8\n```\n\nA entrada acima pode ser exibida como um grafo, conforme a figura abaixo.\n\n![Rinha de Algoritmos](./resources/img/graph1.png)\n\n**Exemplo de Saída 01:**\n```plaintext\n2\n```\n\nNeste exemplo, temos que basta utilizarmos todas as estradas disponíveis para traçar todos os postos avançados. Como as sentinelas sempre estarão nas fronteiras, a muralha de tamanho máximo possui tamanho $2$.\n\nConsideremos outro exemplo deste mesmo problema. Desta vez, suponha que há uma estrada entre os postos $5$ e $1$.\n\n**Exemplo de Entrada 02:**\n\n```plaintext\n8 8\n1 2\n2 3\n3 4\n4 5\n5 6\n5 1\n6 7\n7 8\n```\n\nA entrada acima pode ser exibida como um grafo, conforme a figura abaixo.\n\n![Rinha de Algoritmos](./resources/img/graph2.png)\n\n**Exemplo de Saída 02:**\n```plaintext\n3\n```\n\nNeste caso, podemos compor nossa muralha de modo que esta possua tamanho no máximo $3$, conforme podemos observar na figura abaixo.\n\n![Rinha de Algoritmos](./resources/img/graph3.png)\n\n---\n\n### Problema 03\n\n"
  },
  {
    "path": "resources/instances/problem_01/exemplo_01.txt",
    "content": "22 36\n3\t86\n1\t80\n3\t71\n2\t39\n2\t53\n3\t47\n2\t46\n1\t32\n1\t69\n2\t89\n4\t58\n3\t86\n3\t54\n3\t53\n1\t64\n4\t82\n1\t46\n2\t48\n4\t53\n1\t68\n3\t94\n1\t87\n"
  },
  {
    "path": "resources/instances/problem_01/exemplo_02.txt",
    "content": "9 10\n3\t44\n1\t78\n2\t64\n1\t49\n4\t69\n1\t87\n3\t78\n2\t45\n3\t84\n"
  },
  {
    "path": "resources/instances/problem_01/exemplo_03.txt",
    "content": "25 45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n"
  },
  {
    "path": "resources/instances/problem_01/resultados.txt",
    "content": "exemplo_01.txt\t1194\nexemplo_02.txt\t407\nexemplo_03.txt\t1566\n"
  },
  {
    "path": "resources/instances/problem_02/exemplo_01.txt",
    "content": "40 47\n1 2\n1 24\n2 12\n3 18\n3 22\n4 11\n4 29\n4 32\n5 6\n5 27\n6 12\n6 22\n7 15\n7 17\n8 13\n8 15\n8 36\n9 17\n9 21\n10 18\n10 30\n10 32\n11 40\n12 31\n13 22\n13 31\n14 25\n14 32\n16 19\n16 23\n16 24\n17 20\n18 33\n19 38\n20 23\n21 38\n23 35\n25 39\n26 27\n28 33\n28 35\n29 34\n29 37\n30 34\n33 36\n36 40\n37 39\n"
  },
  {
    "path": "resources/instances/problem_02/exemplo_02.txt",
    "content": "30 35\n1 3\n1 16\n2 9\n2 23\n3 8\n3 23\n4 18\n4 22\n4 30\n5 6\n5 11\n6 9\n6 19\n7 16\n7 18\n7 20\n8 26\n8 27\n9 18\n9 21\n10 13\n10 30\n12 15\n12 22\n13 17\n14 24\n14 28\n15 17\n19 27\n20 21\n21 29\n22 24\n24 26\n25 28\n25 29\n"
  },
  {
    "path": "resources/instances/problem_02/exemplo_03.txt",
    "content": "30 218\n1 3\n1 8\n1 9\n1 11\n1 12\n1 13\n1 14\n1 16\n1 18\n1 20\n1 22\n1 24\n1 26\n1 27\n1 28\n2 8\n2 9\n2 11\n2 12\n2 14\n2 15\n2 19\n2 22\n2 26\n2 29\n3 7\n3 9\n3 10\n3 11\n3 12\n3 14\n3 20\n3 22\n3 23\n3 27\n3 29\n3 30\n4 9\n4 10\n4 11\n4 12\n4 14\n4 16\n4 18\n4 19\n4 21\n4 23\n4 25\n4 29\n4 30\n5 6\n5 9\n5 11\n5 13\n5 14\n5 15\n5 16\n5 17\n5 22\n5 23\n5 24\n5 28\n5 29\n6 8\n6 9\n6 13\n6 14\n6 17\n6 18\n6 19\n6 21\n6 26\n6 29\n7 9\n7 10\n7 11\n7 12\n7 13\n7 17\n7 18\n7 20\n7 22\n7 25\n8 9\n8 12\n8 16\n8 17\n8 21\n8 22\n8 24\n8 26\n8 28\n8 30\n9 11\n9 12\n9 14\n9 18\n9 21\n9 22\n9 23\n9 24\n9 27\n9 28\n9 30\n10 11\n10 12\n10 15\n10 18\n10 20\n10 21\n10 22\n10 27\n10 28\n10 30\n11 12\n11 14\n11 15\n11 16\n11 17\n11 18\n11 19\n11 21\n11 22\n11 23\n11 27\n11 28\n12 13\n12 15\n12 16\n12 20\n12 21\n12 22\n12 23\n12 25\n12 27\n12 29\n13 15\n13 17\n13 19\n13 20\n13 22\n13 23\n13 24\n13 27\n13 28\n13 29\n13 30\n14 15\n14 16\n14 21\n14 22\n14 24\n14 25\n14 27\n15 16\n15 17\n15 18\n15 19\n15 20\n15 23\n15 24\n15 28\n15 29\n16 17\n16 18\n16 19\n16 20\n16 23\n16 24\n16 25\n16 27\n16 28\n16 29\n17 21\n17 22\n17 23\n17 24\n17 28\n18 19\n18 24\n18 25\n18 30\n19 20\n19 22\n19 24\n19 25\n19 29\n19 30\n20 21\n20 22\n20 26\n20 29\n20 30\n21 22\n21 23\n21 24\n21 26\n21 28\n21 30\n22 24\n22 26\n22 27\n22 28\n23 24\n23 28\n24 25\n24 27\n24 28\n25 26\n25 27\n25 30\n26 28\n26 29\n26 30\n27 29\n27 30\n28 29\n29 30\n"
  },
  {
    "path": "resources/instances/problem_02/resultados.txt",
    "content": "exemplo_01.txt 15\nexemplo_02.txt 12\nexemplo_03.txt 27\n"
  },
  {
    "path": "resources/instances/problem_03/results.txt",
    "content": ""
  },
  {
    "path": "submissions/.gitkeep",
    "content": ""
  },
  {
    "path": "submissions/danielsalles/README.md",
    "content": "### Compile with:\n```\ng++ -o problema-1-binary problema-1.cpp -O3\n```\n\n### Run with:\n```\n./problema-1-binary < ../../resources/instances/problem_01/exemplo_01.txt\n```"
  },
  {
    "path": "submissions/danielsalles/problema-1.cpp",
    "content": "#include <iostream>\n#include <vector>\n#include <algorithm>\n\nstruct Seed {\n    int cost;\n    int profit;\n    int space;\n    Seed(int c, int p, int s) : cost(c), profit(p), space(s) {}\n};\n\nint calculateMaxProfit(const std::vector<Seed>& seeds, int availableSpace) {\n    int n = seeds.size();\n    std::vector<int> dp(availableSpace + 1, 0);\n\n    for (int i = 0; i < n; i++) {\n        for (int j = availableSpace; j >= seeds[i].space; j--) {\n            dp[j] = std::max(dp[j], dp[j - seeds[i].space] + seeds[i].profit);\n        }\n    }\n\n    return dp[availableSpace];\n}\n\nint main() {\n    int N, W;\n    std::cin >> N >> W;\n\n    std::vector<Seed> seeds;\n    seeds.reserve(N);\n\n    for(int i = 0; i < N; i++) {\n        int cost, profit, space;\n        std::cin >> space >> profit;\n        cost = 0;\n        seeds.push_back(Seed(cost, profit, space));\n    }\n\n    int maxProfit = calculateMaxProfit(seeds, W);\n    std::cout << maxProfit << std::endl;\n\n    return 0;\n}\n"
  },
  {
    "path": "submissions/devmessias_01_numba_AOT/Makefile",
    "content": "compile:\n\tcd aot && python setup.py build_ext --inplace\n\n\ninstall:\n\tpip install -r requirements.txt\n\ninstall-aot-lib:\n\tcd aot && python setup.py install\n\ncompile-pyc:\n\tpython -m compileall problem_01.py\n\n\nsetup: install compile install-aot-lib compile-pyc\n"
  },
  {
    "path": "submissions/devmessias_01_numba_AOT/README.md",
    "content": "\nEste exemplo usa compilação AOT usando numba para python. Portanto,\né necessário executar a instalação e compilação primeiro\n\n```\nmake setup\n```\n\nO comando acima ira:\n\n- AOT de uma implementação básica usando NUMBA estrategia de memoization (instâncias são pequenas de mais)\n- Instalar o módulo no ambiente\n- compilar o pyc para cache\n\nPara executar para cada instância (troquei espaços por tab na primeira linha que tava mal formatada)\n\n```\npython problem_01.py exemplo_01.txt\n```\n"
  },
  {
    "path": "submissions/devmessias_01_numba_AOT/aot/knapsack.py",
    "content": "from numba import jit, int64\nimport numpy as np\nfrom numba.pycc import CC\n\ncc = CC('knapsack')\ncc.verbose = True\n\n@cc.export('knapsack', 'int64(int64[:, :], int64)')\ndef knapsack(items, capacity):\n    dp = np.zeros(capacity + 1, dtype=np.int64)\n    for weight, value in items:\n        for w in range(capacity, weight - 1, -1):\n            dp[w] = max(dp[w], dp[w - weight] + value)\n    return dp[capacity]\n\nif __name__ == \"__main__\":\n    cc.compile()\n"
  },
  {
    "path": "submissions/devmessias_01_numba_AOT/aot/setup.py",
    "content": "from setuptools import setup\nfrom setuptools.extension import Extension\nfrom Cython.Build import cythonize\n\nextensions = [\n    Extension(\n        name=\"knapsack\",\n        sources=[\"knapsack.py\"]\n    ),\n]\n\nsetup(\n    name=\"knapsack\",\n    ext_modules=cythonize(extensions),\n)\n"
  },
  {
    "path": "submissions/devmessias_01_numba_AOT/exemplo_01.txt",
    "content": "22\t36\n3\t86\n1\t80\n3\t71\n2\t39\n2\t53\n3\t47\n2\t46\n1\t32\n1\t69\n2\t89\n4\t58\n3\t86\n3\t54\n3\t53\n1\t64\n4\t82\n1\t46\n2\t48\n4\t53\n1\t68\n3\t94\n1\t87\n"
  },
  {
    "path": "submissions/devmessias_01_numba_AOT/exemplo_02.txt",
    "content": "9\t10\n3\t44\n1\t78\n2\t64\n1\t49\n4\t69\n1\t87\n3\t78\n2\t45\n3\t84\n"
  },
  {
    "path": "submissions/devmessias_01_numba_AOT/exemplo_03.txt",
    "content": "25\t45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n"
  },
  {
    "path": "submissions/devmessias_01_numba_AOT/problem_01.py",
    "content": "from sys import argv\nfrom numpy import genfromtxt, int32\nimport knapsack\n\n\nif __name__ == \"__main__\":\n  data = genfromtxt(argv[1], delimiter='\\t', dtype=int32)\n  capacity = data[0][1]\n  items = data[1:]\n  solution = knapsack.knapsack(items, capacity)\n  print(solution)\n"
  },
  {
    "path": "submissions/devmessias_01_numba_AOT/requirements.txt",
    "content": "Cython==3.0.8\nllvmlite==0.39.1\nnumba==0.56\nnumpy==1.22\n"
  },
  {
    "path": "submissions/diogosm/Dockerfile",
    "content": "FROM python:3.8\n\nWORKDIR /app\nCOPY . /app\n\nRUN pip install numba\n#RUN apt-get update && apt-get install -y bc\n\nCMD [\"bash\", \"-c\", \"time python3 problema-1.py < /app/exemplo_03.txt\"]\n"
  },
  {
    "path": "submissions/diogosm/README.md",
    "content": "# Para rodar\n\nSe tiver docker: `./run.sh`. Irá retornar a saída e o tempo de execucao. Caso contrário: `python3 problema-1.py < exemplo_XX.txt`. Mude XX para a instância de entrada.\n\n# Tentativa 1 (pd c/ memoization\n\nResultado:\n\n```bash\nreal    0m0.013s\nuser    0m0.013s\nsys     0m0.000s\n```\n\n# Tentativa 2 (com numba) *NOT WORKING*\n\n```bash\nreal    0m0.000s\nuser    0m0.000s\nsys     0m0.000s\n```\n"
  },
  {
    "path": "submissions/diogosm/exemplo_01.txt",
    "content": "22 36\n3\t86\n1\t80\n3\t71\n2\t39\n2\t53\n3\t47\n2\t46\n1\t32\n1\t69\n2\t89\n4\t58\n3\t86\n3\t54\n3\t53\n1\t64\n4\t82\n1\t46\n2\t48\n4\t53\n1\t68\n3\t94\n1\t87\n"
  },
  {
    "path": "submissions/diogosm/exemplo_02.txt",
    "content": "9 10\n3\t44\n1\t78\n2\t64\n1\t49\n4\t69\n1\t87\n3\t78\n2\t45\n3\t84\n"
  },
  {
    "path": "submissions/diogosm/exemplo_03.txt",
    "content": "25 45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n"
  },
  {
    "path": "submissions/diogosm/problema-1.py",
    "content": "import sys\n#from numba import jit, njit\n#import numpy as np\n\nn, s = map(int, next(sys.stdin).strip().split())\ntuples = [tuple(map(int, next(sys.stdin).strip().split())) for _ in range(n)]\n\n## remove solucoes impossiveis\ntuples.sort(key=lambda x: x[1]/x[0], reverse=True)\ntuples = [tup for tup in tuples if tup[0] <= s]\n\nmemoization = {}\n\n## calc pd\n#@njit\ndef calc_lucro(n_aux, s_aux):\n\tif (n_aux, s_aux) in memoization:\n\t\treturn memoization[(n_aux, s_aux)]\n\tif n_aux == 0 or s_aux == 0:\n\t\treturn 0\n\tif tuples[n_aux-1][0] > s_aux:\n\t\tmemoization[(n_aux, s_aux)] = calc_lucro(n_aux - 1, s_aux)\n\telse:\n\t\t## verifico adicionando e nao adicionando\n\t\tmemoization[(n_aux, s_aux)] = max( tuples[n_aux-1][1] + calc_lucro(n_aux-1, s_aux - tuples[n_aux-1][0]),\n\t\t\t\t\t\t\t\t\t\t\tcalc_lucro(n_aux - 1, s_aux))\n\treturn memoization[(n_aux, s_aux)]\n\t\nprint(calc_lucro(n,s))\n#print(memoization)\n"
  },
  {
    "path": "submissions/diogosm/resultados.txt",
    "content": "instances/exemplo_01.txt\t1194\ninstances/exemplo_02.txt\t407\ninstances/exemplo_03.txt\t1566\n"
  },
  {
    "path": "submissions/diogosm/run.sh",
    "content": "#!/bin/bash\n\ndocker build -t python-rinha . && docker run python-rinha\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/Dockerfile",
    "content": "FROM python:3.11.7-alpine3.18\n\n# Install the hyperfine package\nRUN apk --no-cache add hyperfine jq\n\nWORKDIR /app\nCOPY . /app\n\n# Make the script executable\nRUN chmod +x /app/runtime.sh\n\n# Run the script as the default command\nCMD [\"/app/runtime.sh\"]"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/ReadMe.md",
    "content": "# Requisitos\n- ***Docker***\n\n# Como Rodar\n### PowerShell(MS)  *ou*  Shell(Linux)\n> Execute uma linha de cada vez no console, sempre esperando a anterior terminar de executar\n`e não esqueça de escrever o \".\"`\n\n1. Ir ao **diretório** do *Dockerfile*\n- **PowerShell**/***Bash***\n```PowerShell\ncd Path/to/submissions/gabrielng-rj99/Problema_1/Python/\n```\n\n\n2. *Gerar* a **Imagem** do *Dockerfile*\n- **PowerShell**/***Bash***\n```PowerShell\ndocker build -t problem_1:gabrielng-rj99 . \n```\n\n3. *Gerar* um **conteiner** da *imagem* e rodá-lo\n- **PowerShell**/***Bash***\n```PowerShell\ndocker run --cpus=2 --memory=2g --name gng-rj99_p1 problem_1:gabrielng-rj99\n```\n\n- **Resultado Esperado(Print):**\n\n![ExpectedShellPrint](./print.png)\n\n\n4. Caso queira rodar o conteiner novamente (sem gerar num novo conteiner)\n- **PowerShell**/***Bash***\n```PowerShell\ndocker start -a gng-rj99_p1\n```\n\n\n### Para apagar os conteiners da imagem e a imagem:\n\n#### 1. Parar todas os conteiners da imagem \"*problem_1:gabrielng-rj99*\"\n\n---\n\n- **PowerShell** `docker ps -aq --filter ancestor=problem_1:gabrielng-rj99 | ForEach-Object { docker stop $_ }`\n\n- ***Bash*** `docker ps -a | grep problem_1:gabrielng-rj99 | awk '{print $1}' | xargs docker stop`\n\n---\n\n#### 2. Remover todas os conteiners da imagem \"*problem_1:gabrielng-rj99*\"\n\n---\n\n- **PowerShell** `docker ps -aq --filter ancestor=problem_1:gabrielng-rj99 | ForEach-Object { docker rm $_ }`\n\n- ***Bash*** `docker ps -a | grep problem_1:gabrielng-rj99 | awk '{print $1}' | xargs docker rm`\n\n--- \n\n#### 3. Remover a imagem criada\n- **PowerShell**/***Bash***\n```bash\ndocker rmi problem_1:gabrielng-rj99\n```\n\n# Notas:\n\n1. Para timar facilmente os runtimes do dockerfile basta editar o Dockerfile \"run_commands.sh\" (nas linhas \"RUN\" e \"CMD\") para \"runtime.sh\" dependendo do método pra avaliar.\n\n2. Sinta-se a vontade para alterar os parâmetros do benchmark como \nWARMUP e RUNS no runtime.sh\n\n### Rodar mais exemplos/arquivos\n- basta colocar todos os arquivos na pasta \"examples\" abaixo **ANTES** de criar a **imagem** como na foto do **\"*Resultado Esperado*\"**\n> Path / to /submissions/gabrielng-rj99/Problema_1/Python/examples"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/examples/exemplo_01.txt",
    "content": "22 36\n3\t86\n1\t80\n3\t71\n2\t39\n2\t53\n3\t47\n2\t46\n1\t32\n1\t69\n2\t89\n4\t58\n3\t86\n3\t54\n3\t53\n1\t64\n4\t82\n1\t46\n2\t48\n4\t53\n1\t68\n3\t94\n1\t87\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/examples/exemplo_02.txt",
    "content": "9 10\n3\t44\n1\t78\n2\t64\n1\t49\n4\t69\n1\t87\n3\t78\n2\t45\n3\t84\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/examples/exemplo_03.txt",
    "content": "25 45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/handmade_tests.txt",
    "content": "# Run handmade tests\n\ndef run_handmade_tests():\n    file_paths = [\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/exemplo_01.txt\",             #  1194\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/exemplo_02.txt\",             #   407\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/exemplo_03.txt\",             #  1566\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/longruntest.txt\",            # 80762\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/longruntest2.txt\",           # 96601\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/longruntest3.txt\",           # 84067\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/longruntest4.txt\",           # 74789\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/longruntest5.txt\",           #102945\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test01_03.txt\",        #  1581\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test02_03.txt\",        #  1583\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test03_03.txt\",        #  1596\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test03.1_03.txt\",      #  1612\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test04_03.txt\",        #  1597\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test05_03.txt\",        #  1585\n    ]\n\n    for file in file_paths:\n        print(execute_algorithm(file))\n\n\nrun_handmade_tests()"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/longruntest.txt",
    "content": "1509 2000\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/longruntest2.txt",
    "content": "1000 2500\n4\t190\n7\t164\n5\t172\n6\t78\n2\t188\n5\t139\n1\t56\n2\t75\n6\t183\n1\t92\n5\t183\n1\t132\n3\t30\n5\t30\n5\t175\n5\t62\n3\t122\n1\t61\n7\t116\n5\t171\n2\t50\n1\t187\n3\t115\n5\t76\n4\t73\n2\t191\n6\t141\n7\t165\n3\t140\n3\t168\n6\t71\n4\t100\n4\t112\n3\t82\n1\t138\n5\t165\n6\t137\n3\t31\n6\t153\n6\t58\n5\t118\n1\t130\n1\t58\n5\t197\n7\t125\n1\t121\n5\t30\n7\t133\n4\t76\n2\t106\n5\t73\n3\t118\n2\t48\n4\t191\n7\t126\n7\t91\n6\t126\n6\t158\n3\t87\n2\t78\n1\t39\n1\t38\n6\t179\n3\t182\n4\t139\n1\t167\n4\t102\n4\t120\n5\t183\n6\t189\n5\t41\n7\t163\n5\t100\n7\t181\n2\t196\n2\t47\n1\t167\n4\t31\n1\t156\n3\t39\n6\t70\n5\t147\n2\t57\n5\t42\n1\t85\n1\t163\n3\t41\n1\t194\n1\t74\n2\t98\n6\t93\n4\t162\n5\t121\n1\t41\n2\t134\n5\t37\n4\t72\n6\t191\n3\t103\n4\t171\n3\t147\n2\t177\n7\t42\n6\t133\n3\t194\n7\t191\n4\t168\n6\t60\n3\t75\n7\t185\n2\t80\n7\t82\n3\t131\n3\t63\n4\t84\n3\t43\n3\t59\n7\t140\n3\t121\n5\t106\n1\t175\n6\t110\n5\t60\n7\t72\n5\t101\n5\t168\n2\t135\n2\t85\n4\t148\n7\t158\n5\t141\n3\t193\n6\t75\n7\t30\n3\t184\n4\t98\n3\t56\n2\t68\n5\t30\n7\t140\n5\t74\n7\t180\n7\t136\n5\t99\n6\t57\n7\t82\n3\t135\n6\t152\n7\t155\n4\t125\n6\t200\n2\t180\n4\t163\n5\t161\n5\t58\n4\t150\n4\t77\n1\t45\n4\t146\n6\t169\n7\t183\n4\t159\n2\t86\n2\t195\n1\t85\n6\t144\n7\t117\n4\t183\n4\t68\n5\t75\n3\t108\n2\t65\n1\t68\n2\t84\n5\t127\n7\t123\n5\t101\n3\t153\n6\t194\n1\t180\n6\t72\n6\t173\n6\t130\n6\t39\n5\t188\n4\t55\n5\t164\n1\t34\n4\t78\n6\t71\n2\t44\n4\t82\n7\t89\n7\t49\n5\t89\n5\t46\n4\t127\n2\t72\n1\t159\n2\t181\n3\t152\n4\t164\n3\t179\n7\t56\n4\t59\n7\t98\n4\t56\n5\t133\n4\t197\n5\t78\n1\t128\n4\t47\n3\t180\n2\t74\n5\t101\n7\t38\n1\t89\n7\t90\n4\t190\n3\t115\n2\t34\n7\t50\n2\t163\n6\t51\n7\t109\n3\t185\n1\t140\n5\t97\n2\t151\n3\t190\n4\t166\n6\t69\n6\t112\n4\t131\n6\t161\n3\t175\n6\t190\n5\t183\n6\t181\n1\t124\n3\t182\n6\t31\n1\t189\n6\t57\n3\t39\n3\t130\n4\t81\n6\t133\n2\t73\n1\t131\n2\t78\n5\t73\n7\t126\n6\t56\n3\t170\n5\t186\n4\t60\n6\t56\n1\t80\n1\t166\n6\t144\n7\t40\n7\t80\n5\t174\n3\t109\n3\t191\n3\t72\n6\t188\n7\t46\n4\t152\n7\t63\n2\t195\n4\t31\n6\t123\n5\t59\n5\t168\n5\t135\n6\t167\n1\t74\n4\t154\n4\t176\n6\t79\n3\t146\n6\t39\n5\t50\n5\t90\n6\t123\n5\t143\n2\t189\n7\t190\n6\t69\n6\t81\n7\t170\n2\t130\n4\t151\n5\t128\n6\t93\n1\t67\n5\t46\n5\t121\n1\t161\n7\t84\n5\t95\n7\t82\n7\t97\n2\t91\n2\t116\n1\t38\n5\t103\n2\t80\n2\t173\n3\t51\n6\t163\n4\t62\n3\t93\n1\t99\n1\t112\n4\t93\n2\t40\n7\t194\n6\t125\n7\t174\n6\t102\n4\t131\n2\t174\n3\t152\n2\t30\n1\t45\n6\t136\n5\t54\n3\t76\n5\t97\n6\t69\n4\t148\n2\t170\n2\t95\n6\t138\n1\t143\n6\t67\n6\t55\n5\t107\n1\t33\n5\t116\n3\t154\n3\t177\n3\t136\n7\t143\n7\t170\n6\t94\n4\t85\n7\t121\n7\t80\n4\t160\n2\t77\n4\t178\n7\t139\n4\t41\n2\t119\n6\t57\n1\t102\n1\t115\n1\t64\n5\t161\n5\t166\n2\t36\n7\t155\n6\t134\n5\t43\n7\t100\n5\t179\n5\t152\n1\t116\n4\t33\n7\t145\n2\t33\n1\t115\n1\t96\n5\t125\n2\t131\n2\t103\n1\t169\n5\t148\n5\t170\n6\t181\n5\t96\n4\t141\n3\t140\n7\t149\n3\t48\n2\t190\n3\t55\n4\t132\n3\t55\n3\t179\n7\t82\n5\t124\n7\t160\n3\t35\n6\t171\n4\t72\n7\t137\n7\t77\n5\t131\n2\t157\n5\t181\n7\t105\n1\t94\n6\t83\n6\t114\n6\t100\n6\t179\n3\t129\n7\t190\n7\t48\n2\t148\n7\t141\n6\t178\n3\t97\n7\t90\n4\t44\n4\t105\n5\t118\n1\t182\n1\t79\n2\t162\n6\t99\n1\t97\n4\t36\n3\t189\n6\t139\n7\t92\n3\t67\n6\t90\n7\t82\n3\t151\n5\t46\n4\t116\n1\t60\n7\t52\n4\t43\n4\t198\n3\t34\n2\t160\n6\t181\n2\t40\n5\t162\n6\t63\n5\t101\n2\t136\n7\t119\n6\t87\n3\t60\n1\t154\n1\t49\n3\t154\n4\t160\n1\t116\n2\t156\n5\t90\n7\t186\n7\t43\n4\t88\n1\t174\n7\t198\n2\t163\n6\t70\n5\t164\n2\t178\n4\t65\n6\t196\n6\t31\n2\t135\n1\t155\n5\t42\n1\t118\n3\t131\n1\t44\n5\t163\n4\t121\n5\t107\n4\t62\n3\t143\n3\t164\n3\t112\n1\t192\n3\t172\n2\t173\n4\t78\n3\t91\n4\t55\n4\t50\n5\t117\n7\t169\n6\t193\n4\t83\n2\t38\n6\t165\n1\t136\n1\t185\n7\t189\n7\t104\n3\t192\n4\t117\n2\t186\n2\t150\n6\t108\n5\t104\n5\t44\n7\t181\n7\t46\n5\t193\n5\t198\n6\t49\n1\t154\n3\t78\n1\t128\n4\t173\n3\t41\n7\t89\n6\t98\n7\t80\n5\t193\n2\t197\n6\t43\n6\t189\n6\t184\n4\t151\n2\t64\n4\t140\n3\t114\n6\t112\n6\t146\n5\t136\n5\t69\n5\t195\n1\t200\n2\t58\n5\t187\n4\t120\n7\t165\n2\t80\n6\t93\n2\t31\n1\t144\n6\t35\n3\t156\n2\t143\n1\t198\n3\t154\n4\t103\n3\t120\n2\t154\n1\t59\n3\t65\n3\t137\n5\t164\n5\t121\n3\t174\n7\t136\n4\t133\n3\t164\n3\t117\n2\t120\n3\t112\n5\t164\n1\t79\n6\t74\n7\t76\n6\t125\n1\t43\n4\t161\n1\t125\n4\t147\n3\t104\n5\t181\n2\t58\n1\t153\n5\t83\n5\t32\n2\t185\n5\t139\n4\t87\n2\t96\n4\t151\n1\t200\n7\t31\n4\t132\n7\t147\n3\t161\n3\t140\n4\t147\n1\t159\n5\t45\n7\t137\n5\t198\n5\t65\n4\t79\n7\t91\n5\t57\n7\t184\n4\t153\n3\t140\n2\t197\n1\t107\n3\t126\n4\t157\n4\t136\n5\t200\n3\t174\n3\t82\n7\t150\n4\t52\n6\t163\n1\t189\n2\t147\n2\t70\n2\t98\n1\t62\n1\t110\n7\t105\n4\t173\n6\t86\n2\t76\n7\t108\n3\t47\n1\t195\n5\t125\n4\t114\n7\t110\n7\t81\n2\t123\n6\t160\n3\t49\n4\t144\n2\t117\n2\t138\n1\t116\n3\t150\n4\t184\n1\t59\n5\t88\n2\t95\n7\t173\n1\t175\n2\t110\n5\t36\n5\t89\n3\t194\n4\t43\n2\t105\n6\t192\n4\t191\n4\t160\n7\t126\n1\t98\n5\t82\n1\t91\n1\t125\n2\t195\n4\t37\n2\t124\n4\t196\n3\t37\n7\t170\n1\t35\n6\t119\n7\t98\n5\t182\n4\t135\n5\t179\n6\t130\n7\t59\n2\t159\n4\t137\n7\t97\n7\t114\n2\t36\n2\t60\n5\t159\n5\t143\n4\t160\n6\t145\n1\t180\n6\t138\n5\t178\n2\t56\n3\t111\n7\t178\n7\t90\n2\t160\n7\t51\n5\t107\n3\t38\n1\t157\n1\t48\n1\t181\n3\t178\n6\t184\n6\t179\n5\t41\n1\t187\n1\t64\n3\t132\n7\t139\n4\t142\n2\t136\n4\t34\n1\t178\n7\t136\n2\t32\n4\t68\n3\t67\n5\t87\n2\t37\n1\t60\n7\t103\n2\t123\n1\t30\n4\t99\n4\t169\n2\t98\n7\t97\n1\t168\n4\t61\n6\t114\n6\t96\n3\t102\n1\t119\n1\t198\n4\t74\n1\t74\n1\t144\n5\t59\n6\t99\n3\t81\n1\t84\n4\t35\n1\t144\n2\t59\n6\t42\n1\t98\n6\t83\n5\t133\n6\t175\n7\t191\n7\t63\n1\t180\n1\t79\n1\t80\n5\t140\n5\t86\n4\t80\n5\t109\n7\t125\n4\t179\n2\t125\n7\t182\n2\t38\n7\t32\n7\t168\n4\t81\n6\t117\n5\t185\n3\t38\n1\t98\n5\t190\n2\t126\n2\t149\n6\t117\n6\t191\n7\t189\n3\t32\n5\t107\n4\t148\n5\t52\n5\t144\n2\t74\n3\t69\n5\t69\n2\t32\n7\t96\n5\t156\n3\t100\n3\t54\n6\t141\n6\t163\n4\t57\n1\t184\n7\t34\n1\t163\n2\t84\n6\t73\n7\t82\n2\t162\n2\t147\n4\t83\n6\t176\n6\t32\n3\t148\n7\t54\n7\t143\n2\t52\n5\t122\n1\t70\n7\t159\n2\t84\n5\t86\n1\t193\n1\t149\n7\t142\n5\t181\n1\t48\n5\t185\n1\t100\n3\t151\n1\t64\n5\t194\n4\t200\n3\t34\n5\t120\n7\t92\n1\t145\n5\t103\n5\t95\n1\t59\n1\t47\n7\t128\n6\t111\n4\t191\n2\t89\n4\t147\n1\t61\n2\t64\n6\t164\n5\t68\n7\t131\n6\t94\n7\t196\n2\t167\n3\t175\n7\t79\n4\t181\n6\t190\n1\t63\n3\t168\n4\t150\n1\t78\n2\t47\n5\t158\n1\t37\n7\t153\n2\t120\n6\t30\n2\t78\n2\t106\n4\t90\n4\t64\n3\t144\n4\t194\n7\t72\n2\t160\n1\t146\n6\t141\n6\t78\n3\t32\n1\t159\n3\t148\n5\t184\n3\t85\n2\t50\n5\t140\n1\t155\n6\t154\n3\t155\n5\t64\n1\t31\n2\t93\n1\t181\n3\t142\n4\t107\n6\t79\n4\t112\n2\t145\n7\t154\n5\t104\n7\t48\n2\t186\n2\t44\n5\t185\n5\t124\n7\t62\n1\t69\n6\t99\n2\t48\n4\t66\n4\t161\n1\t125\n4\t35\n4\t195\n2\t189\n2\t150\n2\t38\n4\t145\n5\t47\n5\t113\n5\t150\n2\t99\n6\t198\n7\t47\n5\t126\n3\t147\n6\t61\n7\t125\n3\t99\n4\t70\n3\t181\n6\t192\n1\t164\n1\t117\n1\t143\n4\t162\n7\t82\n3\t37\n6\t92\n7\t156\n4\t75\n7\t119\n6\t141\n6\t74\n6\t31\n4\t65\n1\t134\n5\t33\n2\t62\n1\t170\n4\t123\n4\t34\n7\t51\n2\t91\n5\t152\n6\t194\n7\t137\n5\t167\n2\t72\n6\t102\n2\t47\n3\t178\n6\t67\n6\t133\n3\t39\n4\t120\n2\t162\n1\t144\n2\t108\n7\t126\n4\t108\n7\t38\n1\t143\n7\t181\n3\t143\n7\t176\n6\t158\n4\t37\n1\t156\n5\t42\n5\t37\n3\t128\n2\t197\n1\t37\n5\t88\n3\t40\n2\t40\n5\t88\n4\t168\n3\t82\n6\t104\n1\t55\n1\t49\n4\t132\n1\t148\n4\t131\n6\t65\n1\t127\n4\t87\n3\t168\n6\t50\n7\t115\n5\t54\n6\t38\n2\t150\n3\t44\n1\t114\n2\t44\n4\t182\n4\t76\n3\t64\n6\t158\n3\t43\n3\t107\n4\t175\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/longruntest3.txt",
    "content": "1000 2000\n6\t113\n2\t32\n6\t149\n1\t176\n7\t166\n6\t64\n2\t98\n6\t81\n3\t175\n4\t60\n4\t158\n3\t164\n3\t47\n2\t192\n6\t114\n1\t36\n5\t142\n4\t181\n3\t106\n4\t66\n4\t151\n6\t187\n6\t113\n5\t117\n2\t137\n6\t163\n4\t145\n4\t68\n4\t165\n5\t174\n5\t68\n2\t151\n5\t78\n1\t89\n5\t158\n3\t79\n2\t59\n3\t146\n7\t160\n2\t42\n6\t141\n7\t188\n3\t70\n7\t87\n1\t174\n4\t81\n2\t170\n5\t161\n2\t129\n6\t171\n4\t156\n5\t36\n5\t132\n7\t51\n1\t82\n7\t104\n7\t41\n3\t110\n7\t181\n6\t67\n3\t44\n6\t107\n7\t140\n4\t135\n2\t47\n1\t63\n3\t117\n6\t194\n5\t156\n7\t111\n7\t182\n2\t46\n1\t115\n2\t42\n4\t154\n4\t154\n7\t153\n3\t197\n4\t172\n7\t179\n2\t59\n1\t162\n6\t162\n1\t150\n6\t179\n1\t43\n6\t188\n5\t46\n6\t188\n1\t166\n3\t171\n6\t162\n7\t94\n4\t68\n2\t140\n4\t74\n6\t63\n5\t182\n2\t151\n1\t118\n3\t120\n1\t83\n6\t158\n5\t137\n2\t179\n5\t141\n3\t170\n3\t100\n1\t106\n3\t86\n7\t130\n1\t114\n7\t126\n4\t111\n1\t179\n3\t58\n6\t35\n6\t159\n2\t198\n7\t66\n4\t133\n7\t57\n3\t53\n6\t41\n2\t90\n1\t184\n1\t119\n6\t117\n4\t134\n5\t192\n2\t113\n2\t73\n4\t160\n7\t176\n2\t182\n3\t189\n4\t120\n4\t58\n6\t31\n2\t65\n3\t117\n4\t67\n2\t116\n2\t52\n5\t178\n3\t83\n1\t116\n7\t31\n7\t109\n1\t119\n6\t37\n5\t37\n4\t110\n7\t105\n4\t107\n4\t180\n7\t158\n1\t64\n1\t80\n3\t198\n6\t110\n2\t79\n5\t38\n2\t114\n7\t180\n5\t124\n7\t165\n4\t120\n3\t30\n6\t104\n1\t71\n5\t153\n5\t52\n6\t89\n2\t73\n5\t200\n7\t56\n4\t105\n1\t172\n2\t75\n4\t104\n4\t71\n1\t78\n4\t145\n7\t57\n7\t136\n7\t37\n5\t122\n4\t80\n3\t188\n3\t115\n7\t146\n2\t128\n6\t176\n2\t98\n6\t99\n3\t150\n7\t44\n1\t127\n1\t87\n6\t129\n4\t39\n4\t63\n5\t157\n6\t163\n4\t115\n1\t150\n3\t64\n4\t162\n3\t100\n4\t189\n5\t138\n2\t115\n5\t119\n2\t160\n5\t126\n4\t82\n4\t151\n5\t99\n5\t179\n2\t147\n6\t109\n2\t42\n4\t31\n3\t187\n3\t110\n1\t152\n4\t139\n3\t142\n5\t135\n6\t35\n3\t152\n7\t60\n4\t161\n5\t175\n5\t54\n7\t153\n5\t35\n1\t58\n5\t38\n7\t121\n3\t182\n2\t42\n3\t57\n3\t95\n1\t71\n1\t114\n1\t78\n7\t46\n6\t119\n3\t140\n3\t156\n7\t120\n5\t74\n1\t92\n1\t192\n7\t132\n1\t156\n2\t117\n6\t127\n4\t36\n5\t62\n7\t109\n1\t54\n1\t143\n4\t41\n5\t167\n6\t79\n1\t52\n4\t80\n7\t151\n3\t192\n5\t134\n7\t186\n6\t31\n6\t197\n5\t186\n7\t52\n3\t183\n5\t149\n7\t130\n4\t78\n7\t145\n6\t76\n7\t158\n5\t181\n3\t137\n7\t95\n2\t170\n1\t104\n3\t66\n6\t192\n4\t115\n6\t120\n5\t99\n4\t128\n6\t88\n1\t60\n3\t49\n7\t156\n6\t199\n2\t110\n6\t86\n2\t160\n6\t161\n2\t82\n1\t186\n3\t40\n1\t124\n6\t124\n6\t107\n3\t64\n4\t83\n4\t32\n5\t156\n5\t179\n5\t159\n6\t130\n6\t142\n7\t102\n3\t191\n4\t145\n5\t35\n7\t131\n6\t109\n2\t134\n6\t115\n3\t163\n6\t173\n6\t98\n1\t104\n3\t86\n5\t148\n1\t34\n7\t194\n6\t115\n2\t98\n2\t45\n3\t118\n6\t92\n6\t75\n2\t156\n3\t157\n7\t181\n2\t151\n6\t93\n6\t187\n2\t113\n6\t67\n4\t180\n2\t193\n3\t57\n7\t33\n2\t156\n6\t196\n3\t181\n5\t111\n3\t83\n3\t94\n2\t91\n3\t134\n6\t171\n1\t33\n5\t81\n3\t39\n3\t50\n2\t183\n6\t181\n7\t121\n7\t31\n1\t101\n2\t148\n4\t127\n6\t138\n4\t179\n3\t172\n2\t132\n5\t30\n6\t136\n2\t163\n5\t174\n1\t161\n2\t86\n4\t160\n4\t109\n2\t112\n7\t96\n2\t60\n1\t129\n4\t129\n2\t151\n7\t46\n7\t186\n6\t90\n4\t32\n6\t191\n1\t102\n7\t113\n5\t112\n1\t199\n4\t162\n4\t169\n3\t91\n6\t68\n7\t156\n1\t163\n1\t128\n4\t178\n6\t84\n5\t102\n7\t157\n7\t83\n4\t183\n5\t76\n4\t95\n7\t99\n7\t34\n3\t92\n6\t198\n3\t160\n7\t196\n6\t138\n2\t148\n1\t91\n7\t76\n5\t192\n2\t30\n6\t96\n6\t83\n3\t30\n4\t142\n3\t96\n3\t187\n1\t92\n6\t158\n4\t142\n5\t175\n3\t176\n1\t72\n7\t165\n7\t131\n5\t195\n6\t77\n7\t84\n3\t193\n6\t71\n3\t67\n2\t114\n4\t39\n2\t164\n6\t188\n5\t169\n2\t139\n7\t170\n7\t88\n6\t79\n7\t151\n7\t153\n3\t127\n5\t125\n6\t189\n7\t131\n6\t69\n2\t56\n5\t70\n4\t44\n3\t45\n4\t151\n7\t32\n5\t122\n6\t82\n6\t144\n1\t62\n5\t158\n1\t42\n2\t96\n7\t187\n3\t57\n6\t148\n1\t181\n2\t149\n3\t40\n3\t46\n4\t171\n3\t45\n7\t77\n6\t49\n5\t36\n4\t65\n6\t76\n4\t91\n2\t59\n3\t88\n3\t145\n2\t38\n7\t165\n5\t69\n7\t151\n4\t57\n3\t81\n2\t34\n6\t176\n7\t105\n4\t116\n6\t70\n5\t143\n6\t186\n3\t41\n4\t97\n5\t117\n5\t160\n5\t152\n6\t119\n4\t61\n6\t161\n2\t96\n3\t199\n2\t173\n5\t68\n4\t99\n6\t37\n7\t81\n4\t175\n5\t102\n3\t93\n4\t192\n6\t198\n5\t100\n6\t168\n7\t140\n2\t72\n6\t75\n7\t171\n4\t159\n3\t33\n5\t176\n6\t40\n7\t177\n5\t82\n7\t86\n2\t198\n6\t168\n5\t160\n2\t37\n5\t37\n2\t80\n2\t125\n7\t139\n4\t77\n1\t78\n4\t91\n5\t125\n3\t159\n6\t178\n4\t141\n3\t95\n6\t63\n3\t110\n6\t98\n3\t115\n3\t180\n7\t85\n3\t153\n3\t165\n5\t53\n7\t156\n3\t143\n2\t31\n3\t37\n2\t175\n7\t64\n7\t163\n7\t159\n1\t109\n5\t176\n5\t77\n4\t40\n6\t120\n5\t101\n3\t56\n6\t60\n6\t127\n6\t137\n7\t174\n2\t145\n5\t169\n5\t46\n4\t104\n1\t132\n4\t140\n4\t54\n4\t179\n2\t32\n2\t56\n4\t59\n1\t199\n7\t40\n6\t87\n2\t39\n2\t96\n1\t167\n6\t135\n7\t97\n7\t153\n4\t99\n6\t179\n4\t81\n4\t86\n2\t33\n7\t135\n2\t104\n7\t193\n6\t33\n4\t45\n7\t125\n7\t76\n3\t175\n3\t94\n1\t112\n3\t108\n5\t169\n1\t93\n4\t157\n4\t104\n6\t139\n4\t196\n1\t92\n1\t105\n4\t174\n4\t189\n1\t88\n1\t93\n4\t98\n1\t71\n4\t54\n7\t72\n3\t70\n2\t141\n5\t151\n7\t162\n4\t188\n3\t106\n3\t156\n5\t121\n6\t91\n7\t63\n4\t70\n2\t116\n4\t115\n4\t31\n7\t78\n6\t181\n7\t160\n6\t88\n4\t70\n3\t90\n5\t105\n5\t176\n2\t66\n6\t178\n6\t177\n5\t166\n4\t126\n3\t40\n6\t35\n2\t161\n7\t34\n5\t142\n5\t151\n3\t197\n2\t74\n5\t104\n2\t90\n2\t193\n1\t148\n4\t63\n6\t60\n3\t192\n5\t139\n5\t126\n4\t98\n1\t199\n5\t195\n7\t180\n5\t194\n6\t136\n7\t167\n7\t101\n7\t72\n3\t84\n1\t79\n6\t88\n3\t132\n1\t103\n3\t107\n4\t93\n4\t41\n1\t152\n1\t67\n5\t73\n5\t57\n6\t151\n7\t50\n7\t125\n5\t117\n7\t135\n5\t56\n6\t56\n2\t69\n2\t115\n1\t53\n1\t52\n3\t92\n2\t115\n4\t102\n4\t113\n5\t46\n2\t43\n3\t167\n6\t35\n7\t114\n4\t54\n7\t105\n5\t97\n5\t74\n4\t159\n2\t157\n4\t127\n2\t121\n7\t72\n6\t117\n5\t76\n5\t183\n4\t87\n6\t43\n5\t55\n5\t38\n7\t54\n5\t106\n5\t193\n5\t52\n6\t177\n5\t151\n4\t194\n1\t102\n3\t200\n4\t37\n7\t172\n2\t46\n6\t105\n1\t117\n2\t133\n3\t184\n6\t134\n2\t106\n1\t119\n4\t69\n5\t73\n3\t177\n1\t52\n4\t146\n2\t155\n5\t39\n1\t72\n7\t108\n7\t178\n4\t57\n4\t112\n4\t129\n6\t178\n1\t174\n7\t132\n4\t148\n4\t194\n2\t155\n3\t40\n6\t65\n6\t36\n4\t73\n2\t196\n7\t100\n1\t113\n7\t139\n3\t100\n5\t90\n2\t106\n1\t104\n1\t42\n3\t127\n2\t45\n7\t142\n2\t187\n1\t179\n7\t163\n1\t58\n6\t92\n7\t120\n4\t110\n6\t185\n5\t103\n7\t44\n7\t183\n5\t44\n5\t77\n5\t40\n7\t92\n7\t177\n6\t59\n2\t172\n7\t70\n5\t149\n4\t110\n4\t132\n1\t119\n2\t133\n3\t58\n3\t195\n7\t153\n7\t152\n3\t61\n1\t75\n3\t110\n1\t194\n1\t177\n5\t181\n1\t131\n3\t112\n5\t184\n6\t177\n1\t171\n4\t152\n1\t165\n1\t194\n5\t141\n7\t121\n5\t77\n6\t130\n2\t73\n7\t195\n2\t89\n6\t183\n4\t181\n2\t82\n7\t84\n6\t100\n3\t135\n6\t34\n2\t192\n3\t187\n2\t112\n7\t129\n3\t183\n1\t178\n1\t180\n7\t180\n3\t152\n3\t62\n2\t89\n7\t146\n6\t165\n6\t35\n5\t142\n2\t92\n7\t84\n5\t176\n5\t76\n1\t117\n3\t38\n1\t75\n4\t152\n6\t137\n5\t56\n4\t171\n4\t65\n3\t93\n5\t83\n6\t38\n2\t35\n5\t111\n1\t150\n5\t188\n1\t49\n1\t145\n2\t65\n5\t96\n2\t147\n3\t165\n2\t182\n4\t84\n5\t167\n1\t121\n1\t53\n3\t89\n2\t31\n4\t153\n6\t161\n6\t139\n3\t167\n3\t53\n4\t117\n7\t180\n3\t38\n5\t120\n5\t119\n7\t165\n2\t130\n3\t113\n3\t199\n2\t34\n5\t102\n3\t183\n1\t121\n7\t62\n2\t143\n6\t148\n2\t137\n2\t127\n1\t184\n6\t182\n5\t159\n6\t169\n7\t73\n1\t197\n5\t51\n4\t190\n7\t70\n4\t48\n1\t182\n4\t123\n1\t67\n7\t188\n5\t106\n7\t184\n4\t109\n5\t170\n2\t174\n4\t88\n6\t99\n5\t36\n3\t82\n7\t109\n2\t153\n4\t128\n3\t152\n7\t49\n7\t129\n5\t38\n1\t139\n6\t190\n1\t151\n6\t97\n3\t75\n6\t95\n2\t56\n7\t103\n2\t116\n2\t138\n4\t91\n5\t179\n6\t158\n6\t56\n4\t113\n4\t46\n7\t117\n6\t162\n4\t71\n4\t150\n4\t170\n3\t104\n3\t127\n7\t146\n4\t178\n6\t121\n5\t51\n1\t188\n4\t192\n1\t153\n5\t197\n2\t151\n6\t95\n5\t53\n3\t94\n1\t190\n5\t31\n1\t144\n6\t109\n5\t109\n2\t200\n3\t131\n2\t35\n7\t117\n6\t156\n1\t151\n6\t175\n7\t68\n6\t33\n2\t86\n3\t59\n3\t49\n6\t108\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/longruntest4.txt",
    "content": "1000 1500\n6\t152\n3\t34\n1\t151\n6\t198\n5\t126\n7\t133\n2\t167\n6\t114\n7\t165\n2\t144\n7\t55\n1\t50\n7\t174\n6\t98\n1\t151\n7\t87\n4\t37\n2\t195\n5\t45\n1\t127\n1\t92\n1\t169\n1\t36\n3\t171\n1\t131\n2\t128\n7\t137\n6\t58\n3\t162\n3\t170\n3\t174\n6\t113\n2\t179\n5\t151\n7\t30\n3\t152\n3\t162\n1\t148\n6\t157\n7\t70\n4\t58\n6\t181\n4\t100\n4\t134\n5\t193\n2\t39\n3\t152\n6\t139\n3\t182\n4\t40\n2\t157\n7\t117\n6\t70\n5\t36\n5\t94\n2\t81\n3\t103\n4\t140\n1\t110\n6\t31\n6\t35\n5\t171\n4\t136\n2\t46\n1\t41\n3\t31\n7\t40\n4\t130\n4\t57\n2\t164\n2\t144\n6\t155\n5\t79\n4\t188\n6\t167\n1\t193\n7\t64\n2\t92\n4\t68\n4\t149\n3\t62\n1\t111\n1\t181\n2\t196\n3\t67\n7\t94\n7\t49\n5\t185\n7\t84\n5\t150\n4\t126\n2\t86\n2\t107\n5\t177\n2\t153\n5\t127\n4\t179\n7\t74\n7\t142\n5\t167\n2\t132\n3\t99\n2\t188\n2\t58\n3\t69\n1\t133\n3\t51\n4\t167\n1\t77\n7\t182\n2\t55\n2\t60\n3\t57\n7\t66\n3\t104\n2\t161\n1\t81\n6\t108\n7\t44\n6\t150\n1\t195\n7\t44\n7\t85\n4\t67\n2\t171\n7\t136\n3\t50\n2\t129\n6\t119\n3\t157\n7\t79\n3\t143\n4\t80\n6\t61\n2\t52\n1\t172\n4\t62\n3\t101\n3\t83\n6\t164\n4\t168\n6\t74\n1\t106\n3\t75\n3\t115\n6\t122\n3\t134\n2\t54\n5\t145\n6\t73\n6\t40\n7\t112\n3\t97\n6\t129\n1\t107\n1\t180\n2\t35\n6\t40\n2\t200\n4\t77\n5\t127\n2\t119\n7\t90\n1\t71\n3\t149\n2\t120\n4\t132\n5\t119\n5\t136\n7\t115\n5\t123\n5\t161\n5\t155\n2\t69\n7\t169\n4\t80\n2\t167\n5\t68\n2\t79\n6\t154\n7\t146\n4\t151\n2\t174\n1\t165\n4\t63\n3\t169\n7\t136\n3\t120\n4\t182\n4\t96\n1\t118\n7\t63\n3\t163\n3\t190\n6\t90\n6\t117\n5\t157\n6\t87\n7\t149\n6\t125\n6\t135\n2\t145\n7\t110\n2\t148\n4\t35\n2\t50\n7\t200\n5\t77\n2\t44\n6\t97\n7\t187\n2\t100\n1\t127\n6\t34\n2\t57\n1\t44\n5\t146\n2\t67\n3\t72\n3\t172\n3\t160\n6\t139\n3\t64\n3\t76\n7\t179\n5\t143\n6\t56\n3\t55\n4\t114\n6\t139\n6\t97\n2\t142\n2\t187\n1\t53\n6\t30\n5\t131\n3\t197\n2\t113\n2\t191\n2\t42\n4\t112\n6\t175\n4\t44\n2\t89\n5\t77\n5\t64\n7\t65\n6\t80\n1\t164\n7\t46\n1\t36\n1\t59\n5\t116\n6\t111\n4\t68\n7\t151\n5\t147\n2\t49\n7\t91\n4\t69\n3\t68\n5\t155\n5\t122\n6\t89\n7\t200\n6\t92\n7\t31\n3\t99\n6\t45\n1\t152\n6\t102\n3\t132\n5\t163\n3\t166\n7\t64\n1\t135\n1\t154\n4\t158\n1\t71\n4\t121\n4\t60\n5\t119\n7\t135\n5\t100\n6\t160\n6\t44\n6\t66\n3\t45\n1\t73\n4\t64\n1\t37\n5\t89\n2\t74\n1\t164\n5\t189\n3\t185\n3\t127\n3\t177\n7\t127\n7\t196\n4\t99\n5\t195\n7\t62\n3\t74\n5\t110\n1\t137\n1\t114\n2\t75\n2\t67\n4\t189\n5\t41\n3\t114\n3\t193\n5\t62\n3\t33\n1\t100\n7\t110\n3\t150\n3\t121\n6\t36\n5\t174\n3\t120\n6\t139\n2\t192\n5\t74\n1\t161\n2\t168\n2\t135\n1\t173\n5\t147\n5\t59\n5\t35\n3\t108\n1\t45\n2\t64\n2\t99\n3\t63\n3\t176\n4\t119\n2\t171\n5\t135\n4\t132\n3\t128\n4\t38\n3\t146\n7\t182\n7\t177\n3\t36\n1\t128\n2\t143\n1\t159\n1\t46\n6\t40\n5\t30\n5\t71\n5\t140\n5\t100\n3\t165\n5\t86\n1\t144\n4\t184\n2\t30\n7\t54\n6\t148\n5\t172\n4\t133\n6\t147\n1\t200\n2\t58\n7\t85\n5\t32\n2\t198\n2\t163\n6\t53\n7\t44\n7\t33\n6\t110\n1\t187\n4\t127\n2\t196\n1\t131\n3\t119\n6\t179\n6\t148\n1\t44\n4\t194\n4\t84\n2\t80\n6\t155\n5\t113\n6\t175\n2\t89\n3\t113\n2\t34\n6\t60\n3\t133\n2\t136\n3\t103\n4\t63\n1\t94\n5\t37\n1\t134\n3\t92\n6\t194\n3\t163\n2\t148\n4\t199\n3\t138\n7\t49\n2\t57\n7\t166\n5\t176\n7\t154\n2\t68\n4\t186\n6\t95\n4\t175\n3\t90\n3\t124\n1\t45\n4\t197\n6\t131\n5\t55\n5\t68\n3\t33\n2\t111\n7\t40\n7\t41\n7\t61\n3\t54\n3\t180\n5\t138\n7\t134\n3\t39\n4\t124\n4\t160\n6\t40\n7\t154\n5\t96\n2\t31\n3\t88\n7\t190\n7\t197\n3\t133\n5\t184\n6\t36\n3\t43\n4\t45\n3\t49\n6\t192\n1\t59\n4\t59\n4\t105\n1\t192\n2\t145\n4\t55\n5\t191\n4\t30\n3\t139\n7\t97\n3\t112\n4\t39\n6\t182\n4\t70\n7\t187\n7\t133\n6\t92\n2\t157\n6\t79\n2\t33\n7\t118\n5\t176\n5\t102\n3\t138\n6\t115\n7\t195\n3\t74\n5\t118\n2\t200\n1\t135\n7\t73\n2\t126\n4\t161\n3\t144\n4\t99\n5\t87\n6\t33\n6\t56\n1\t104\n7\t119\n5\t195\n2\t190\n4\t184\n2\t130\n5\t129\n5\t153\n1\t104\n1\t140\n3\t64\n2\t187\n3\t91\n2\t149\n7\t44\n3\t39\n1\t156\n7\t178\n2\t55\n3\t74\n4\t166\n7\t149\n3\t45\n2\t86\n5\t35\n4\t76\n1\t58\n7\t140\n1\t132\n3\t114\n6\t145\n4\t161\n2\t79\n1\t75\n4\t74\n1\t180\n1\t178\n7\t194\n4\t119\n2\t157\n5\t118\n2\t62\n5\t136\n4\t43\n4\t62\n1\t44\n5\t115\n3\t88\n5\t48\n6\t52\n1\t111\n3\t34\n3\t83\n1\t67\n1\t119\n7\t55\n1\t156\n4\t177\n7\t192\n5\t126\n4\t143\n4\t82\n5\t65\n7\t191\n4\t93\n5\t93\n2\t88\n7\t121\n6\t112\n2\t58\n2\t197\n3\t65\n6\t104\n1\t196\n7\t191\n3\t122\n6\t59\n4\t186\n6\t198\n5\t94\n4\t60\n4\t41\n7\t175\n1\t179\n7\t150\n1\t200\n3\t111\n7\t90\n2\t144\n6\t73\n4\t57\n1\t136\n6\t173\n7\t132\n6\t152\n4\t132\n3\t59\n6\t46\n2\t129\n7\t40\n6\t92\n1\t139\n6\t120\n6\t156\n5\t134\n3\t181\n1\t114\n2\t192\n2\t175\n7\t149\n4\t145\n1\t71\n3\t128\n7\t154\n7\t91\n4\t179\n4\t196\n3\t191\n6\t94\n4\t168\n7\t197\n4\t142\n5\t117\n4\t171\n2\t141\n7\t86\n3\t173\n2\t188\n5\t170\n4\t60\n3\t173\n2\t156\n1\t105\n1\t43\n4\t156\n3\t66\n3\t103\n6\t56\n1\t106\n5\t38\n5\t59\n3\t76\n5\t121\n6\t199\n2\t141\n4\t198\n2\t32\n3\t108\n1\t128\n1\t175\n4\t42\n2\t126\n4\t136\n3\t63\n4\t80\n2\t80\n2\t83\n2\t75\n2\t153\n3\t63\n3\t193\n5\t164\n3\t44\n1\t171\n7\t106\n4\t196\n2\t199\n3\t108\n5\t89\n1\t105\n2\t117\n3\t78\n2\t45\n5\t100\n2\t51\n6\t30\n2\t82\n1\t133\n1\t157\n7\t107\n6\t178\n4\t173\n4\t161\n4\t194\n5\t197\n1\t178\n3\t133\n4\t165\n4\t125\n6\t179\n2\t158\n3\t163\n2\t75\n3\t60\n7\t68\n5\t100\n4\t68\n3\t112\n6\t192\n5\t36\n4\t166\n6\t200\n1\t120\n7\t200\n4\t111\n3\t99\n2\t125\n7\t31\n1\t56\n6\t72\n7\t60\n7\t30\n2\t41\n2\t164\n7\t77\n1\t146\n5\t129\n7\t67\n7\t156\n2\t167\n6\t184\n3\t174\n2\t179\n1\t161\n1\t64\n1\t168\n7\t200\n5\t104\n1\t73\n4\t197\n5\t154\n6\t82\n2\t122\n2\t190\n4\t115\n1\t94\n3\t140\n4\t174\n4\t61\n2\t140\n1\t145\n6\t89\n1\t155\n6\t124\n2\t91\n7\t106\n2\t78\n3\t100\n5\t154\n6\t60\n4\t155\n5\t162\n6\t166\n5\t108\n5\t90\n5\t187\n6\t173\n7\t65\n3\t149\n7\t188\n7\t100\n2\t73\n4\t94\n1\t91\n5\t194\n6\t123\n5\t198\n7\t154\n3\t100\n5\t176\n7\t186\n2\t159\n6\t50\n2\t174\n4\t80\n1\t83\n7\t178\n6\t191\n2\t194\n1\t142\n7\t80\n5\t147\n7\t171\n2\t94\n3\t160\n3\t35\n6\t193\n5\t165\n6\t97\n5\t90\n2\t139\n5\t142\n6\t108\n1\t143\n3\t70\n2\t47\n2\t179\n6\t151\n4\t96\n6\t31\n4\t130\n4\t192\n3\t115\n5\t44\n5\t33\n5\t110\n3\t57\n4\t105\n7\t45\n2\t107\n5\t174\n4\t57\n1\t108\n6\t90\n1\t46\n6\t116\n6\t56\n1\t151\n7\t43\n3\t138\n1\t57\n1\t124\n2\t94\n6\t98\n3\t168\n6\t97\n2\t94\n6\t64\n3\t158\n6\t124\n4\t121\n1\t183\n2\t96\n2\t155\n4\t155\n5\t116\n3\t123\n4\t79\n2\t132\n4\t98\n5\t65\n6\t131\n1\t160\n6\t172\n7\t145\n3\t44\n2\t181\n3\t33\n7\t178\n4\t190\n7\t34\n7\t161\n5\t69\n1\t37\n1\t138\n4\t42\n5\t112\n4\t101\n2\t187\n7\t167\n3\t177\n1\t192\n6\t90\n2\t177\n2\t56\n4\t34\n6\t136\n7\t108\n1\t54\n3\t185\n1\t173\n1\t77\n5\t116\n5\t89\n5\t36\n2\t161\n7\t63\n7\t42\n6\t180\n3\t193\n6\t109\n7\t79\n7\t192\n5\t51\n1\t181\n6\t165\n5\t115\n5\t59\n4\t195\n3\t113\n1\t52\n7\t94\n6\t59\n6\t41\n1\t56\n3\t151\n5\t146\n7\t92\n6\t30\n7\t59\n2\t102\n4\t33\n5\t114\n7\t110\n3\t78\n3\t144\n5\t175\n2\t87\n1\t162\n3\t185\n7\t173\n5\t40\n6\t66\n3\t148\n4\t184\n6\t139\n5\t172\n5\t103\n5\t162\n3\t171\n6\t61\n1\t131\n6\t185\n2\t50\n7\t104\n1\t80\n4\t52\n7\t36\n2\t106\n3\t172\n4\t172\n2\t76\n7\t50\n4\t121\n6\t63\n3\t94\n2\t97\n4\t119\n2\t161\n7\t78\n5\t86\n6\t86\n7\t167\n4\t58\n2\t145\n2\t190\n2\t113\n5\t125\n1\t198\n4\t81\n1\t155\n4\t113\n4\t75\n1\t143\n2\t143\n5\t187\n6\t184\n6\t134\n2\t141\n5\t130\n5\t58\n5\t180\n2\t174\n7\t176\n3\t188\n5\t57\n7\t53\n3\t56\n4\t53\n7\t183\n7\t160\n2\t170\n6\t185\n5\t42\n4\t124\n6\t182\n7\t197\n4\t96\n4\t125\n7\t159\n6\t79\n6\t172\n7\t58\n6\t145\n7\t107\n3\t115\n2\t139\n5\t134\n3\t135\n6\t65\n5\t119\n2\t88\n2\t71\n3\t104\n7\t172\n5\t84\n7\t105\n1\t89\n7\t107\n6\t44\n7\t33\n1\t97\n2\t35\n3\t132\n4\t36\n6\t63\n1\t178\n4\t160\n3\t35\n5\t152\n7\t117\n3\t47\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/longruntest5.txt",
    "content": "1000 3000\n2\t172\n1\t74\n2\t95\n3\t160\n1\t41\n1\t41\n4\t98\n2\t131\n2\t52\n7\t195\n5\t129\n5\t122\n7\t171\n3\t71\n3\t89\n2\t73\n4\t52\n2\t128\n7\t179\n3\t113\n6\t199\n6\t187\n3\t164\n6\t77\n7\t200\n6\t127\n5\t184\n1\t98\n2\t104\n7\t129\n4\t128\n6\t111\n6\t110\n6\t186\n7\t145\n2\t110\n1\t190\n4\t57\n4\t169\n2\t169\n2\t33\n1\t99\n1\t154\n3\t176\n4\t69\n1\t117\n7\t33\n1\t53\n6\t152\n3\t72\n7\t104\n2\t38\n2\t101\n2\t128\n2\t101\n5\t151\n3\t115\n7\t117\n6\t94\n3\t128\n2\t65\n5\t30\n6\t30\n4\t151\n6\t175\n5\t45\n6\t75\n6\t55\n1\t69\n5\t41\n1\t88\n6\t89\n6\t115\n2\t114\n2\t153\n6\t77\n5\t182\n2\t91\n6\t49\n4\t140\n6\t107\n6\t106\n6\t154\n4\t50\n6\t139\n6\t93\n1\t34\n1\t168\n1\t107\n5\t76\n4\t72\n1\t126\n4\t180\n4\t126\n5\t77\n3\t124\n5\t131\n5\t58\n7\t91\n3\t164\n3\t183\n4\t133\n1\t165\n3\t75\n5\t104\n1\t74\n5\t162\n6\t86\n7\t190\n5\t93\n3\t137\n1\t97\n5\t86\n4\t195\n1\t159\n1\t200\n2\t64\n3\t142\n3\t109\n6\t166\n7\t98\n6\t155\n4\t186\n4\t75\n3\t199\n2\t100\n7\t97\n6\t130\n7\t165\n6\t141\n5\t72\n3\t130\n4\t67\n5\t146\n6\t101\n5\t90\n2\t60\n2\t181\n5\t41\n1\t43\n5\t118\n3\t85\n2\t94\n2\t57\n3\t59\n2\t114\n5\t113\n5\t152\n1\t83\n7\t139\n5\t169\n2\t45\n2\t158\n5\t62\n7\t75\n7\t107\n1\t65\n7\t189\n3\t109\n1\t165\n5\t116\n6\t161\n2\t137\n6\t193\n4\t143\n7\t80\n5\t132\n1\t98\n6\t92\n3\t173\n5\t131\n1\t174\n2\t41\n6\t76\n7\t65\n3\t135\n2\t56\n5\t134\n5\t70\n2\t194\n3\t38\n3\t57\n4\t57\n6\t162\n7\t90\n1\t116\n6\t190\n5\t119\n4\t114\n4\t185\n4\t52\n3\t162\n6\t60\n3\t118\n7\t155\n7\t51\n6\t114\n2\t95\n6\t111\n6\t139\n4\t149\n7\t98\n3\t40\n2\t79\n2\t109\n3\t125\n3\t63\n4\t87\n4\t76\n2\t62\n4\t131\n1\t32\n6\t174\n7\t91\n3\t60\n1\t171\n3\t107\n2\t167\n4\t171\n4\t41\n6\t118\n4\t101\n2\t103\n7\t153\n4\t127\n6\t128\n2\t54\n7\t180\n7\t118\n1\t147\n5\t79\n2\t72\n3\t140\n5\t128\n4\t36\n4\t157\n2\t125\n4\t196\n2\t71\n3\t197\n3\t179\n1\t52\n2\t195\n5\t196\n4\t85\n3\t89\n5\t140\n5\t70\n2\t41\n3\t124\n7\t76\n1\t59\n1\t98\n4\t34\n3\t46\n2\t126\n7\t90\n6\t67\n6\t63\n6\t81\n2\t103\n3\t34\n7\t55\n1\t180\n7\t112\n3\t80\n6\t40\n1\t127\n3\t86\n4\t40\n2\t176\n1\t119\n4\t149\n3\t122\n2\t189\n6\t186\n2\t189\n6\t137\n3\t75\n5\t112\n3\t83\n1\t35\n1\t199\n3\t66\n7\t117\n5\t190\n4\t40\n5\t106\n3\t37\n3\t136\n6\t156\n3\t150\n3\t57\n3\t59\n7\t122\n1\t184\n7\t35\n1\t77\n4\t83\n1\t139\n5\t135\n6\t170\n4\t200\n5\t197\n1\t30\n7\t168\n3\t97\n2\t105\n7\t162\n3\t182\n3\t69\n7\t156\n5\t106\n4\t146\n7\t34\n3\t172\n4\t31\n7\t145\n5\t31\n2\t86\n4\t136\n2\t106\n7\t37\n7\t71\n2\t104\n4\t55\n5\t63\n7\t79\n5\t72\n6\t35\n5\t83\n3\t40\n5\t40\n5\t193\n2\t154\n3\t183\n5\t62\n6\t80\n7\t34\n4\t73\n4\t165\n2\t116\n3\t174\n6\t77\n7\t157\n7\t127\n3\t114\n6\t78\n2\t184\n4\t50\n5\t73\n4\t76\n5\t138\n7\t51\n2\t75\n1\t182\n3\t164\n4\t77\n4\t73\n2\t189\n7\t108\n3\t128\n4\t92\n7\t40\n2\t82\n1\t132\n5\t186\n6\t108\n7\t104\n7\t137\n2\t36\n6\t111\n7\t131\n3\t145\n7\t112\n4\t146\n2\t119\n1\t49\n7\t194\n3\t47\n5\t38\n2\t92\n6\t162\n5\t100\n5\t56\n6\t182\n1\t186\n6\t139\n4\t137\n3\t47\n7\t105\n6\t175\n1\t39\n5\t57\n6\t90\n4\t105\n1\t153\n7\t55\n3\t50\n1\t181\n2\t39\n3\t138\n5\t163\n6\t36\n7\t130\n6\t42\n3\t147\n1\t48\n3\t93\n2\t71\n2\t158\n3\t58\n4\t48\n5\t31\n5\t148\n6\t68\n6\t151\n4\t180\n1\t105\n2\t185\n3\t140\n4\t138\n7\t57\n3\t79\n3\t190\n4\t135\n6\t135\n5\t62\n1\t127\n7\t49\n3\t46\n5\t144\n2\t53\n4\t62\n4\t44\n7\t88\n6\t91\n2\t190\n1\t194\n4\t195\n5\t102\n5\t101\n1\t75\n5\t57\n2\t108\n6\t134\n6\t195\n1\t94\n1\t185\n7\t110\n6\t107\n1\t51\n5\t151\n7\t94\n3\t101\n5\t179\n6\t58\n6\t126\n2\t128\n3\t49\n6\t109\n2\t121\n2\t64\n2\t145\n3\t153\n5\t61\n5\t75\n7\t60\n7\t33\n1\t72\n7\t86\n6\t122\n7\t172\n3\t153\n2\t160\n4\t140\n1\t173\n3\t121\n6\t49\n4\t101\n6\t117\n2\t38\n3\t107\n5\t115\n5\t147\n1\t173\n5\t66\n4\t198\n5\t124\n6\t80\n6\t79\n2\t91\n3\t126\n2\t38\n1\t111\n6\t196\n1\t187\n1\t114\n6\t105\n4\t126\n4\t150\n4\t61\n6\t86\n3\t33\n6\t136\n6\t39\n2\t118\n2\t91\n7\t101\n6\t93\n1\t39\n6\t121\n1\t168\n5\t71\n5\t61\n2\t115\n5\t64\n3\t151\n6\t197\n5\t174\n1\t100\n6\t185\n5\t137\n6\t41\n7\t105\n6\t146\n3\t45\n4\t52\n7\t79\n2\t141\n7\t145\n1\t65\n4\t107\n6\t66\n7\t81\n4\t157\n3\t198\n6\t80\n2\t72\n7\t116\n7\t102\n3\t148\n1\t109\n5\t141\n2\t148\n3\t125\n3\t145\n5\t44\n2\t167\n4\t196\n1\t166\n1\t133\n7\t173\n5\t166\n1\t65\n4\t31\n1\t72\n4\t174\n5\t36\n2\t70\n5\t42\n3\t148\n7\t193\n3\t38\n6\t143\n7\t175\n4\t90\n5\t91\n3\t172\n3\t183\n5\t146\n5\t165\n3\t64\n3\t186\n4\t87\n2\t199\n5\t127\n1\t53\n3\t184\n3\t137\n2\t38\n1\t191\n5\t39\n1\t110\n1\t156\n3\t139\n4\t35\n7\t190\n6\t41\n1\t159\n7\t31\n7\t152\n5\t129\n6\t135\n6\t118\n2\t168\n5\t160\n5\t187\n5\t171\n6\t140\n3\t172\n5\t190\n5\t149\n3\t83\n5\t176\n2\t165\n1\t43\n2\t169\n4\t138\n5\t194\n7\t197\n2\t111\n4\t101\n2\t157\n5\t94\n4\t169\n3\t189\n5\t174\n5\t168\n3\t193\n2\t148\n4\t128\n7\t135\n7\t198\n3\t76\n6\t106\n3\t128\n2\t74\n6\t62\n2\t192\n2\t70\n4\t30\n7\t180\n1\t94\n4\t80\n4\t149\n4\t170\n1\t164\n4\t101\n7\t190\n4\t118\n3\t137\n4\t40\n2\t84\n4\t172\n3\t75\n4\t90\n2\t102\n1\t152\n5\t192\n5\t57\n6\t77\n4\t147\n5\t131\n1\t96\n6\t41\n5\t31\n3\t112\n6\t176\n6\t187\n6\t55\n4\t103\n3\t101\n1\t114\n3\t79\n7\t34\n7\t191\n1\t153\n5\t185\n5\t170\n6\t69\n2\t89\n5\t174\n6\t88\n4\t121\n1\t115\n6\t34\n1\t46\n5\t123\n7\t143\n5\t95\n4\t166\n7\t159\n3\t118\n1\t61\n7\t46\n7\t127\n2\t56\n7\t52\n2\t31\n6\t167\n1\t78\n4\t102\n4\t94\n2\t72\n5\t95\n1\t107\n6\t147\n1\t34\n6\t84\n5\t129\n5\t151\n6\t126\n1\t130\n5\t112\n7\t154\n1\t109\n4\t37\n7\t62\n6\t136\n6\t94\n3\t173\n7\t128\n2\t68\n2\t83\n2\t125\n7\t102\n4\t138\n2\t46\n7\t72\n4\t52\n6\t43\n5\t172\n4\t134\n6\t98\n1\t49\n1\t172\n1\t199\n4\t113\n1\t168\n4\t180\n7\t142\n7\t101\n3\t86\n6\t153\n7\t70\n2\t103\n2\t102\n3\t40\n1\t194\n7\t67\n4\t131\n4\t108\n3\t103\n1\t41\n7\t152\n7\t80\n2\t85\n3\t147\n4\t176\n4\t143\n1\t81\n1\t67\n7\t54\n7\t153\n5\t107\n3\t197\n6\t33\n4\t78\n3\t88\n3\t94\n4\t72\n1\t192\n6\t68\n1\t67\n4\t129\n7\t78\n3\t114\n6\t141\n4\t93\n2\t58\n2\t91\n4\t134\n2\t32\n3\t35\n4\t100\n4\t64\n3\t131\n1\t50\n5\t76\n5\t46\n5\t70\n4\t75\n1\t103\n7\t36\n3\t193\n6\t135\n3\t103\n1\t165\n3\t143\n7\t177\n3\t141\n3\t76\n5\t100\n2\t54\n5\t84\n3\t48\n2\t183\n4\t136\n7\t161\n6\t106\n2\t91\n3\t165\n6\t134\n6\t67\n6\t183\n3\t144\n6\t47\n4\t185\n2\t123\n3\t131\n2\t76\n7\t37\n7\t33\n6\t165\n6\t152\n1\t165\n3\t112\n7\t156\n6\t87\n1\t157\n6\t171\n2\t124\n6\t79\n2\t144\n2\t126\n6\t140\n6\t163\n5\t76\n6\t96\n4\t197\n6\t51\n7\t30\n4\t92\n2\t165\n7\t126\n7\t169\n6\t160\n7\t118\n2\t98\n3\t42\n3\t55\n1\t191\n6\t74\n1\t108\n4\t52\n2\t124\n6\t159\n5\t99\n3\t129\n1\t83\n4\t82\n5\t32\n6\t122\n4\t123\n1\t167\n1\t82\n4\t81\n3\t146\n2\t107\n6\t169\n3\t98\n4\t102\n5\t185\n2\t118\n4\t120\n7\t113\n2\t55\n6\t138\n4\t191\n1\t142\n5\t77\n6\t171\n1\t189\n3\t130\n1\t106\n2\t117\n1\t141\n3\t199\n7\t52\n2\t129\n4\t32\n4\t186\n1\t166\n1\t114\n4\t193\n7\t50\n3\t30\n6\t103\n5\t122\n3\t189\n5\t128\n5\t171\n1\t145\n3\t83\n2\t129\n4\t64\n6\t62\n5\t103\n1\t193\n4\t183\n2\t175\n6\t104\n1\t48\n3\t163\n5\t180\n7\t170\n2\t50\n1\t31\n4\t137\n2\t172\n1\t144\n1\t174\n7\t35\n7\t165\n3\t151\n1\t193\n2\t176\n1\t72\n4\t146\n1\t188\n7\t37\n4\t147\n2\t79\n2\t135\n6\t111\n2\t73\n5\t174\n5\t119\n6\t87\n4\t41\n1\t45\n7\t34\n5\t150\n6\t53\n3\t116\n2\t59\n1\t109\n1\t192\n5\t71\n1\t36\n5\t103\n5\t113\n1\t87\n1\t31\n2\t155\n2\t31\n1\t137\n7\t130\n1\t125\n7\t134\n6\t129\n7\t148\n3\t31\n3\t36\n6\t91\n2\t152\n6\t39\n7\t98\n7\t33\n6\t146\n6\t122\n3\t82\n2\t95\n1\t114\n1\t152\n4\t169\n3\t178\n1\t165\n4\t140\n3\t39\n4\t169\n5\t74\n7\t49\n4\t117\n3\t144\n3\t144\n5\t60\n5\t161\n5\t177\n3\t160\n4\t49\n3\t122\n7\t118\n6\t78\n7\t194\n5\t74\n1\t92\n6\t59\n2\t79\n5\t146\n5\t30\n2\t59\n7\t126\n7\t143\n4\t46\n3\t194\n1\t129\n5\t126\n7\t145\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test01_03.txt",
    "content": "26 45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test02_03.txt",
    "content": "26 45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n2\t30\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test03.1_03.txt",
    "content": "26 47\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n2\t30\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test03_03.txt",
    "content": "26 46\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n2\t30\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test04_03.txt",
    "content": "26 46\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t44\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n2\t30\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test05_03.txt",
    "content": "25 46\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t61\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/problema-1.py",
    "content": "import  sys\ndef knapsack(SPACE, ARRAY):\n    n = len(ARRAY)\n    dp = [0] * (SPACE + 1)\n\n    for i in range(n):\n        wi = ARRAY[i][0]        # Weight\n        vi = ARRAY[i][1]        # Value\n        for j in range(SPACE, wi - 1, -1):\n            dp[j] = max(dp[j], vi + dp[j - wi])\n\n    return dp[SPACE]\n\ndef execute_algorithm(file_path):\n    with open(file_path, 'r') as file:\n        _n, W = map(int, file.readline().split())\n        \n        file_array = []\n\n        for line in file:\n            row = list(map(int, line.split()))\n            row += [row[1]/row[0]]\n            file_array.append(row)\n        \n        return knapsack(W, file_array)\n\n\nif __name__ == '__main__':\n    file_path = sys.argv[1]\n    print(f\"{execute_algorithm(file_path):>10}\")"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/run_commands.sh",
    "content": "#!/bin/sh\n\nMFNL=0          # Max FileName Length Start\n\nfor file in examples/*\ndo\n  filename=$(basename $file)\n  len=$(echo -n \"$filename\" | wc -c)\n  if [ $len -gt $MFNL ]; then\n    MFNL=$len\n  fi\ndone\n\nclear\n\nprintf \"%-${MFNL}s  %s \\t \\n\" \"FileName\" \"Respostas\"\nfor file in examples/*\ndo\n  output=$(python problema-1.py $file)\n  filename=$(basename $file)\n  printf \"%-${MFNL}s $output\\n\" \"$filename\"\ndone"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/runtime.sh",
    "content": "#!/bin/sh\n\nWARMUP=20\nRUNS=20\nSUM_MEANS=0\nFILE_COUNT=0\nMFNL=0          # Max FileName Length Start\n\nfor file in examples/*\ndo\n  filename=$(basename $file)\n  len=$(echo -n \"$filename\" | wc -c)\n  if [ $len -gt $MFNL ]; then\n    MFNL=$len\n  fi\ndone\n\n\nclear\n\necho -e \"\\n\\nRodará um (Hyperfine) Benchmark de $RUNS runs para cada arquivo\"\necho -e \"Depois pego as médias numa jq, e calculo ao final a soma das médias\"\necho -e \"Isso foi feito para facilitar a execução e visualização dos resultados\\n\\n\"\n\nprintf \"%-${MFNL}s  %s \\t %s \\n\" \"FileName\" \"Respostas\" \"Runtime\"\nfor file in examples/*\ndo\n  result=$(hyperfine --warmup $WARMUP --runs $RUNS \"python problema-1.py $file\" --export-json /tmp/hyperfine_results.json 2>/dev/null)\n  \n  output=$(python problema-1.py $file)\n  filename=$(basename $file)\n  mean=$(jq -r '.results | .[0].mean' /tmp/hyperfine_results.json)\n  \n  formatted_mean=$(printf \"%.9f\" $mean)\n  SUM_MEANS=$(echo \"$SUM_MEANS + $mean\" | bc)\n  FILE_COUNT=$((FILE_COUNT + 1))\n  \n  printf \"%-${MFNL}s $output \\t $formatted_mean s\\n\" \"$filename\"\ndone\n\nAVERAGE_MEAN=$(echo \"scale=9; $SUM_MEANS / $FILE_COUNT\" | bc)\n\nTOTAL_RUNTIME=$(printf \"%.9f\" $SUM_MEANS)\nAVERAGE_MEAN=$(printf \"%.9f\" $AVERAGE_MEAN)\n\necho -e \"\\nTotal Runtime:   \\t\\t $TOTAL_RUNTIME s\\n\"\necho -e \"\\nAvarage Runtime: \\t\\t $AVERAGE_MEAN s\\n\\n\""
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Python/test_hyperfine.sh",
    "content": "#!/bin/sh\n\n#Hyperfine all examples one by one\nclear\n\nWARMUP=10\nRUNS=200\n\nfor file in examples/*\ndo\n  namefile=$(basename $file)\n  output=$(python problema-1.py $file)\n  echo -e \"\\nResposta do $namefile  ->  $output\"\n  echo -e \"Benchmark\"\n  hyperfine --warmup $WARMUP --runs $RUNS \"python problema-1.py $file\" 2>/dev/null | grep -v \"^Benchmark 1: python problema-1.py\"\ndone\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/Cargo.toml",
    "content": "[package]\nname = \"problema_1\"\nversion = \"0.1.0\"\nedition = \"2021\"\n\n# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html\n\n[dependencies]"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/Dockerfile",
    "content": "FROM rust:1.75-alpine3.18\n\n# Install the hyperfine package\nRUN apk --no-cache add hyperfine jq\n\nWORKDIR /app\nCOPY . /app\n\n# Convert line endings of the script to Unix format and executable\nRUN dos2unix /app/run_commands.sh\nRUN chmod +x /app/run_commands.sh\n\n# Run the script as the default command\nCMD [\"/app/run_commands.sh\"]"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/ReadMe.md",
    "content": "# Requisitos\n- ***Docker***\n\n# Como Rodar\n### PowerShell(MS)  *ou*  Shell(Linux)\n> Execute uma linha de cada vez no console, sempre esperando a anterior terminar de executar\n`e não esqueça de escrever o \".\"`\n\n1. Ir ao **diretório** do *Dockerfile*\n- **PowerShell**/***Bash***\n```PowerShell\ncd Path/to/submissions/gabrielng-rj99/Problema_1/Rust/\n```\n\n\n2. *Gerar* a **Imagem** do *Dockerfile*\n- **PowerShell**/***Bash***\n```PowerShell\ndocker build -t problem_1:gabrielng-rj99 . \n```\n\n3. *Gerar* um **conteiner** da *imagem* e rodá-lo\n- **PowerShell**/***Bash***\n```PowerShell\ndocker run --cpus=2 --memory=2g --name gng-rj99_p1 problem_1:gabrielng-rj99\n```\n\n- **Resultado Esperado(Print):**\n\n![ExpectedShellPrint](./print.png)\n\n\n4. Caso queira rodar o conteiner novamente (sem gerar num novo conteiner)\n- **PowerShell**/***Bash***\n```PowerShell\ndocker start -a gng-rj99_p1\n```\n\n\n### Para apagar os conteiners da imagem e a imagem:\n\n#### 1. Parar todas os conteiners da imagem \"*problem_1:gabrielng-rj99*\"\n\n---\n\n- **PowerShell** `docker ps -aq --filter ancestor=problem_1:gabrielng-rj99 | ForEach-Object { docker stop $_ }`\n\n- ***Bash*** `docker ps -a | grep problem_1:gabrielng-rj99 | awk '{print $1}' | xargs docker stop`\n\n---\n\n#### 2. Remover todas os conteiners da imagem \"*problem_1:gabrielng-rj99*\"\n\n---\n\n- **PowerShell** `docker ps -aq --filter ancestor=problem_1:gabrielng-rj99 | ForEach-Object { docker rm $_ }`\n\n- ***Bash*** `docker ps -a | grep problem_1:gabrielng-rj99 | awk '{print $1}' | xargs docker rm`\n\n--- \n\n#### 3. Remover a imagem criada\n- **PowerShell**/***Bash***\n```bash\ndocker rmi problem_1:gabrielng-rj99\n```\n\n# Notas:\n\n1. Sinta-se a vontade para alterar os parâmetros do benchmark como \nWARMUP e RUNS no run_commands.sh\n\n### Rodar mais exemplos/arquivos\n- basta colocar todos os arquivos na pasta \"examples\" abaixo **ANTES** de criar a **imagem** como na foto do **\"*Resultado Esperado*\"**\n> Path / to /submissions/gabrielng-rj99/Problema_1/Rust/examples"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/examples/exemplo_01.txt",
    "content": "22 36\n3\t86\n1\t80\n3\t71\n2\t39\n2\t53\n3\t47\n2\t46\n1\t32\n1\t69\n2\t89\n4\t58\n3\t86\n3\t54\n3\t53\n1\t64\n4\t82\n1\t46\n2\t48\n4\t53\n1\t68\n3\t94\n1\t87\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/examples/exemplo_02.txt",
    "content": "9 10\n3\t44\n1\t78\n2\t64\n1\t49\n4\t69\n1\t87\n3\t78\n2\t45\n3\t84\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/examples/exemplo_03.txt",
    "content": "25 45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/handmade_tests.txt",
    "content": "# Run handmade tests\n\ndef run_handmade_tests():\n    file_paths = [\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/exemplo_01.txt\",             #  1194\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/exemplo_02.txt\",             #   407\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/exemplo_03.txt\",             #  1566\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/longruntest.txt\",            # 80762\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/longruntest2.txt\",           # 96601\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/longruntest3.txt\",           # 84067\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/longruntest4.txt\",           # 74789\n        \"submissions/gabrielng-rj99/Problema_1/Python/examples/longruntest5.txt\",           #102945\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test01_03.txt\",        #  1581\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test02_03.txt\",        #  1583\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test03_03.txt\",        #  1596\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test03.1_03.txt\",      #  1612\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test04_03.txt\",        #  1597\n        \"submissions/gabrielng-rj99/Problema_1/Python/handmade_tests/test05_03.txt\",        #  1585\n    ]\n\n    for file in file_paths:\n        print(execute_algorithm(file))\n\n\nrun_handmade_tests()"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/longruntest.txt",
    "content": "1509 2000\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/longruntest2.txt",
    "content": "1000 2500\n4\t190\n7\t164\n5\t172\n6\t78\n2\t188\n5\t139\n1\t56\n2\t75\n6\t183\n1\t92\n5\t183\n1\t132\n3\t30\n5\t30\n5\t175\n5\t62\n3\t122\n1\t61\n7\t116\n5\t171\n2\t50\n1\t187\n3\t115\n5\t76\n4\t73\n2\t191\n6\t141\n7\t165\n3\t140\n3\t168\n6\t71\n4\t100\n4\t112\n3\t82\n1\t138\n5\t165\n6\t137\n3\t31\n6\t153\n6\t58\n5\t118\n1\t130\n1\t58\n5\t197\n7\t125\n1\t121\n5\t30\n7\t133\n4\t76\n2\t106\n5\t73\n3\t118\n2\t48\n4\t191\n7\t126\n7\t91\n6\t126\n6\t158\n3\t87\n2\t78\n1\t39\n1\t38\n6\t179\n3\t182\n4\t139\n1\t167\n4\t102\n4\t120\n5\t183\n6\t189\n5\t41\n7\t163\n5\t100\n7\t181\n2\t196\n2\t47\n1\t167\n4\t31\n1\t156\n3\t39\n6\t70\n5\t147\n2\t57\n5\t42\n1\t85\n1\t163\n3\t41\n1\t194\n1\t74\n2\t98\n6\t93\n4\t162\n5\t121\n1\t41\n2\t134\n5\t37\n4\t72\n6\t191\n3\t103\n4\t171\n3\t147\n2\t177\n7\t42\n6\t133\n3\t194\n7\t191\n4\t168\n6\t60\n3\t75\n7\t185\n2\t80\n7\t82\n3\t131\n3\t63\n4\t84\n3\t43\n3\t59\n7\t140\n3\t121\n5\t106\n1\t175\n6\t110\n5\t60\n7\t72\n5\t101\n5\t168\n2\t135\n2\t85\n4\t148\n7\t158\n5\t141\n3\t193\n6\t75\n7\t30\n3\t184\n4\t98\n3\t56\n2\t68\n5\t30\n7\t140\n5\t74\n7\t180\n7\t136\n5\t99\n6\t57\n7\t82\n3\t135\n6\t152\n7\t155\n4\t125\n6\t200\n2\t180\n4\t163\n5\t161\n5\t58\n4\t150\n4\t77\n1\t45\n4\t146\n6\t169\n7\t183\n4\t159\n2\t86\n2\t195\n1\t85\n6\t144\n7\t117\n4\t183\n4\t68\n5\t75\n3\t108\n2\t65\n1\t68\n2\t84\n5\t127\n7\t123\n5\t101\n3\t153\n6\t194\n1\t180\n6\t72\n6\t173\n6\t130\n6\t39\n5\t188\n4\t55\n5\t164\n1\t34\n4\t78\n6\t71\n2\t44\n4\t82\n7\t89\n7\t49\n5\t89\n5\t46\n4\t127\n2\t72\n1\t159\n2\t181\n3\t152\n4\t164\n3\t179\n7\t56\n4\t59\n7\t98\n4\t56\n5\t133\n4\t197\n5\t78\n1\t128\n4\t47\n3\t180\n2\t74\n5\t101\n7\t38\n1\t89\n7\t90\n4\t190\n3\t115\n2\t34\n7\t50\n2\t163\n6\t51\n7\t109\n3\t185\n1\t140\n5\t97\n2\t151\n3\t190\n4\t166\n6\t69\n6\t112\n4\t131\n6\t161\n3\t175\n6\t190\n5\t183\n6\t181\n1\t124\n3\t182\n6\t31\n1\t189\n6\t57\n3\t39\n3\t130\n4\t81\n6\t133\n2\t73\n1\t131\n2\t78\n5\t73\n7\t126\n6\t56\n3\t170\n5\t186\n4\t60\n6\t56\n1\t80\n1\t166\n6\t144\n7\t40\n7\t80\n5\t174\n3\t109\n3\t191\n3\t72\n6\t188\n7\t46\n4\t152\n7\t63\n2\t195\n4\t31\n6\t123\n5\t59\n5\t168\n5\t135\n6\t167\n1\t74\n4\t154\n4\t176\n6\t79\n3\t146\n6\t39\n5\t50\n5\t90\n6\t123\n5\t143\n2\t189\n7\t190\n6\t69\n6\t81\n7\t170\n2\t130\n4\t151\n5\t128\n6\t93\n1\t67\n5\t46\n5\t121\n1\t161\n7\t84\n5\t95\n7\t82\n7\t97\n2\t91\n2\t116\n1\t38\n5\t103\n2\t80\n2\t173\n3\t51\n6\t163\n4\t62\n3\t93\n1\t99\n1\t112\n4\t93\n2\t40\n7\t194\n6\t125\n7\t174\n6\t102\n4\t131\n2\t174\n3\t152\n2\t30\n1\t45\n6\t136\n5\t54\n3\t76\n5\t97\n6\t69\n4\t148\n2\t170\n2\t95\n6\t138\n1\t143\n6\t67\n6\t55\n5\t107\n1\t33\n5\t116\n3\t154\n3\t177\n3\t136\n7\t143\n7\t170\n6\t94\n4\t85\n7\t121\n7\t80\n4\t160\n2\t77\n4\t178\n7\t139\n4\t41\n2\t119\n6\t57\n1\t102\n1\t115\n1\t64\n5\t161\n5\t166\n2\t36\n7\t155\n6\t134\n5\t43\n7\t100\n5\t179\n5\t152\n1\t116\n4\t33\n7\t145\n2\t33\n1\t115\n1\t96\n5\t125\n2\t131\n2\t103\n1\t169\n5\t148\n5\t170\n6\t181\n5\t96\n4\t141\n3\t140\n7\t149\n3\t48\n2\t190\n3\t55\n4\t132\n3\t55\n3\t179\n7\t82\n5\t124\n7\t160\n3\t35\n6\t171\n4\t72\n7\t137\n7\t77\n5\t131\n2\t157\n5\t181\n7\t105\n1\t94\n6\t83\n6\t114\n6\t100\n6\t179\n3\t129\n7\t190\n7\t48\n2\t148\n7\t141\n6\t178\n3\t97\n7\t90\n4\t44\n4\t105\n5\t118\n1\t182\n1\t79\n2\t162\n6\t99\n1\t97\n4\t36\n3\t189\n6\t139\n7\t92\n3\t67\n6\t90\n7\t82\n3\t151\n5\t46\n4\t116\n1\t60\n7\t52\n4\t43\n4\t198\n3\t34\n2\t160\n6\t181\n2\t40\n5\t162\n6\t63\n5\t101\n2\t136\n7\t119\n6\t87\n3\t60\n1\t154\n1\t49\n3\t154\n4\t160\n1\t116\n2\t156\n5\t90\n7\t186\n7\t43\n4\t88\n1\t174\n7\t198\n2\t163\n6\t70\n5\t164\n2\t178\n4\t65\n6\t196\n6\t31\n2\t135\n1\t155\n5\t42\n1\t118\n3\t131\n1\t44\n5\t163\n4\t121\n5\t107\n4\t62\n3\t143\n3\t164\n3\t112\n1\t192\n3\t172\n2\t173\n4\t78\n3\t91\n4\t55\n4\t50\n5\t117\n7\t169\n6\t193\n4\t83\n2\t38\n6\t165\n1\t136\n1\t185\n7\t189\n7\t104\n3\t192\n4\t117\n2\t186\n2\t150\n6\t108\n5\t104\n5\t44\n7\t181\n7\t46\n5\t193\n5\t198\n6\t49\n1\t154\n3\t78\n1\t128\n4\t173\n3\t41\n7\t89\n6\t98\n7\t80\n5\t193\n2\t197\n6\t43\n6\t189\n6\t184\n4\t151\n2\t64\n4\t140\n3\t114\n6\t112\n6\t146\n5\t136\n5\t69\n5\t195\n1\t200\n2\t58\n5\t187\n4\t120\n7\t165\n2\t80\n6\t93\n2\t31\n1\t144\n6\t35\n3\t156\n2\t143\n1\t198\n3\t154\n4\t103\n3\t120\n2\t154\n1\t59\n3\t65\n3\t137\n5\t164\n5\t121\n3\t174\n7\t136\n4\t133\n3\t164\n3\t117\n2\t120\n3\t112\n5\t164\n1\t79\n6\t74\n7\t76\n6\t125\n1\t43\n4\t161\n1\t125\n4\t147\n3\t104\n5\t181\n2\t58\n1\t153\n5\t83\n5\t32\n2\t185\n5\t139\n4\t87\n2\t96\n4\t151\n1\t200\n7\t31\n4\t132\n7\t147\n3\t161\n3\t140\n4\t147\n1\t159\n5\t45\n7\t137\n5\t198\n5\t65\n4\t79\n7\t91\n5\t57\n7\t184\n4\t153\n3\t140\n2\t197\n1\t107\n3\t126\n4\t157\n4\t136\n5\t200\n3\t174\n3\t82\n7\t150\n4\t52\n6\t163\n1\t189\n2\t147\n2\t70\n2\t98\n1\t62\n1\t110\n7\t105\n4\t173\n6\t86\n2\t76\n7\t108\n3\t47\n1\t195\n5\t125\n4\t114\n7\t110\n7\t81\n2\t123\n6\t160\n3\t49\n4\t144\n2\t117\n2\t138\n1\t116\n3\t150\n4\t184\n1\t59\n5\t88\n2\t95\n7\t173\n1\t175\n2\t110\n5\t36\n5\t89\n3\t194\n4\t43\n2\t105\n6\t192\n4\t191\n4\t160\n7\t126\n1\t98\n5\t82\n1\t91\n1\t125\n2\t195\n4\t37\n2\t124\n4\t196\n3\t37\n7\t170\n1\t35\n6\t119\n7\t98\n5\t182\n4\t135\n5\t179\n6\t130\n7\t59\n2\t159\n4\t137\n7\t97\n7\t114\n2\t36\n2\t60\n5\t159\n5\t143\n4\t160\n6\t145\n1\t180\n6\t138\n5\t178\n2\t56\n3\t111\n7\t178\n7\t90\n2\t160\n7\t51\n5\t107\n3\t38\n1\t157\n1\t48\n1\t181\n3\t178\n6\t184\n6\t179\n5\t41\n1\t187\n1\t64\n3\t132\n7\t139\n4\t142\n2\t136\n4\t34\n1\t178\n7\t136\n2\t32\n4\t68\n3\t67\n5\t87\n2\t37\n1\t60\n7\t103\n2\t123\n1\t30\n4\t99\n4\t169\n2\t98\n7\t97\n1\t168\n4\t61\n6\t114\n6\t96\n3\t102\n1\t119\n1\t198\n4\t74\n1\t74\n1\t144\n5\t59\n6\t99\n3\t81\n1\t84\n4\t35\n1\t144\n2\t59\n6\t42\n1\t98\n6\t83\n5\t133\n6\t175\n7\t191\n7\t63\n1\t180\n1\t79\n1\t80\n5\t140\n5\t86\n4\t80\n5\t109\n7\t125\n4\t179\n2\t125\n7\t182\n2\t38\n7\t32\n7\t168\n4\t81\n6\t117\n5\t185\n3\t38\n1\t98\n5\t190\n2\t126\n2\t149\n6\t117\n6\t191\n7\t189\n3\t32\n5\t107\n4\t148\n5\t52\n5\t144\n2\t74\n3\t69\n5\t69\n2\t32\n7\t96\n5\t156\n3\t100\n3\t54\n6\t141\n6\t163\n4\t57\n1\t184\n7\t34\n1\t163\n2\t84\n6\t73\n7\t82\n2\t162\n2\t147\n4\t83\n6\t176\n6\t32\n3\t148\n7\t54\n7\t143\n2\t52\n5\t122\n1\t70\n7\t159\n2\t84\n5\t86\n1\t193\n1\t149\n7\t142\n5\t181\n1\t48\n5\t185\n1\t100\n3\t151\n1\t64\n5\t194\n4\t200\n3\t34\n5\t120\n7\t92\n1\t145\n5\t103\n5\t95\n1\t59\n1\t47\n7\t128\n6\t111\n4\t191\n2\t89\n4\t147\n1\t61\n2\t64\n6\t164\n5\t68\n7\t131\n6\t94\n7\t196\n2\t167\n3\t175\n7\t79\n4\t181\n6\t190\n1\t63\n3\t168\n4\t150\n1\t78\n2\t47\n5\t158\n1\t37\n7\t153\n2\t120\n6\t30\n2\t78\n2\t106\n4\t90\n4\t64\n3\t144\n4\t194\n7\t72\n2\t160\n1\t146\n6\t141\n6\t78\n3\t32\n1\t159\n3\t148\n5\t184\n3\t85\n2\t50\n5\t140\n1\t155\n6\t154\n3\t155\n5\t64\n1\t31\n2\t93\n1\t181\n3\t142\n4\t107\n6\t79\n4\t112\n2\t145\n7\t154\n5\t104\n7\t48\n2\t186\n2\t44\n5\t185\n5\t124\n7\t62\n1\t69\n6\t99\n2\t48\n4\t66\n4\t161\n1\t125\n4\t35\n4\t195\n2\t189\n2\t150\n2\t38\n4\t145\n5\t47\n5\t113\n5\t150\n2\t99\n6\t198\n7\t47\n5\t126\n3\t147\n6\t61\n7\t125\n3\t99\n4\t70\n3\t181\n6\t192\n1\t164\n1\t117\n1\t143\n4\t162\n7\t82\n3\t37\n6\t92\n7\t156\n4\t75\n7\t119\n6\t141\n6\t74\n6\t31\n4\t65\n1\t134\n5\t33\n2\t62\n1\t170\n4\t123\n4\t34\n7\t51\n2\t91\n5\t152\n6\t194\n7\t137\n5\t167\n2\t72\n6\t102\n2\t47\n3\t178\n6\t67\n6\t133\n3\t39\n4\t120\n2\t162\n1\t144\n2\t108\n7\t126\n4\t108\n7\t38\n1\t143\n7\t181\n3\t143\n7\t176\n6\t158\n4\t37\n1\t156\n5\t42\n5\t37\n3\t128\n2\t197\n1\t37\n5\t88\n3\t40\n2\t40\n5\t88\n4\t168\n3\t82\n6\t104\n1\t55\n1\t49\n4\t132\n1\t148\n4\t131\n6\t65\n1\t127\n4\t87\n3\t168\n6\t50\n7\t115\n5\t54\n6\t38\n2\t150\n3\t44\n1\t114\n2\t44\n4\t182\n4\t76\n3\t64\n6\t158\n3\t43\n3\t107\n4\t175\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/longruntest3.txt",
    "content": "1000 2000\n6\t113\n2\t32\n6\t149\n1\t176\n7\t166\n6\t64\n2\t98\n6\t81\n3\t175\n4\t60\n4\t158\n3\t164\n3\t47\n2\t192\n6\t114\n1\t36\n5\t142\n4\t181\n3\t106\n4\t66\n4\t151\n6\t187\n6\t113\n5\t117\n2\t137\n6\t163\n4\t145\n4\t68\n4\t165\n5\t174\n5\t68\n2\t151\n5\t78\n1\t89\n5\t158\n3\t79\n2\t59\n3\t146\n7\t160\n2\t42\n6\t141\n7\t188\n3\t70\n7\t87\n1\t174\n4\t81\n2\t170\n5\t161\n2\t129\n6\t171\n4\t156\n5\t36\n5\t132\n7\t51\n1\t82\n7\t104\n7\t41\n3\t110\n7\t181\n6\t67\n3\t44\n6\t107\n7\t140\n4\t135\n2\t47\n1\t63\n3\t117\n6\t194\n5\t156\n7\t111\n7\t182\n2\t46\n1\t115\n2\t42\n4\t154\n4\t154\n7\t153\n3\t197\n4\t172\n7\t179\n2\t59\n1\t162\n6\t162\n1\t150\n6\t179\n1\t43\n6\t188\n5\t46\n6\t188\n1\t166\n3\t171\n6\t162\n7\t94\n4\t68\n2\t140\n4\t74\n6\t63\n5\t182\n2\t151\n1\t118\n3\t120\n1\t83\n6\t158\n5\t137\n2\t179\n5\t141\n3\t170\n3\t100\n1\t106\n3\t86\n7\t130\n1\t114\n7\t126\n4\t111\n1\t179\n3\t58\n6\t35\n6\t159\n2\t198\n7\t66\n4\t133\n7\t57\n3\t53\n6\t41\n2\t90\n1\t184\n1\t119\n6\t117\n4\t134\n5\t192\n2\t113\n2\t73\n4\t160\n7\t176\n2\t182\n3\t189\n4\t120\n4\t58\n6\t31\n2\t65\n3\t117\n4\t67\n2\t116\n2\t52\n5\t178\n3\t83\n1\t116\n7\t31\n7\t109\n1\t119\n6\t37\n5\t37\n4\t110\n7\t105\n4\t107\n4\t180\n7\t158\n1\t64\n1\t80\n3\t198\n6\t110\n2\t79\n5\t38\n2\t114\n7\t180\n5\t124\n7\t165\n4\t120\n3\t30\n6\t104\n1\t71\n5\t153\n5\t52\n6\t89\n2\t73\n5\t200\n7\t56\n4\t105\n1\t172\n2\t75\n4\t104\n4\t71\n1\t78\n4\t145\n7\t57\n7\t136\n7\t37\n5\t122\n4\t80\n3\t188\n3\t115\n7\t146\n2\t128\n6\t176\n2\t98\n6\t99\n3\t150\n7\t44\n1\t127\n1\t87\n6\t129\n4\t39\n4\t63\n5\t157\n6\t163\n4\t115\n1\t150\n3\t64\n4\t162\n3\t100\n4\t189\n5\t138\n2\t115\n5\t119\n2\t160\n5\t126\n4\t82\n4\t151\n5\t99\n5\t179\n2\t147\n6\t109\n2\t42\n4\t31\n3\t187\n3\t110\n1\t152\n4\t139\n3\t142\n5\t135\n6\t35\n3\t152\n7\t60\n4\t161\n5\t175\n5\t54\n7\t153\n5\t35\n1\t58\n5\t38\n7\t121\n3\t182\n2\t42\n3\t57\n3\t95\n1\t71\n1\t114\n1\t78\n7\t46\n6\t119\n3\t140\n3\t156\n7\t120\n5\t74\n1\t92\n1\t192\n7\t132\n1\t156\n2\t117\n6\t127\n4\t36\n5\t62\n7\t109\n1\t54\n1\t143\n4\t41\n5\t167\n6\t79\n1\t52\n4\t80\n7\t151\n3\t192\n5\t134\n7\t186\n6\t31\n6\t197\n5\t186\n7\t52\n3\t183\n5\t149\n7\t130\n4\t78\n7\t145\n6\t76\n7\t158\n5\t181\n3\t137\n7\t95\n2\t170\n1\t104\n3\t66\n6\t192\n4\t115\n6\t120\n5\t99\n4\t128\n6\t88\n1\t60\n3\t49\n7\t156\n6\t199\n2\t110\n6\t86\n2\t160\n6\t161\n2\t82\n1\t186\n3\t40\n1\t124\n6\t124\n6\t107\n3\t64\n4\t83\n4\t32\n5\t156\n5\t179\n5\t159\n6\t130\n6\t142\n7\t102\n3\t191\n4\t145\n5\t35\n7\t131\n6\t109\n2\t134\n6\t115\n3\t163\n6\t173\n6\t98\n1\t104\n3\t86\n5\t148\n1\t34\n7\t194\n6\t115\n2\t98\n2\t45\n3\t118\n6\t92\n6\t75\n2\t156\n3\t157\n7\t181\n2\t151\n6\t93\n6\t187\n2\t113\n6\t67\n4\t180\n2\t193\n3\t57\n7\t33\n2\t156\n6\t196\n3\t181\n5\t111\n3\t83\n3\t94\n2\t91\n3\t134\n6\t171\n1\t33\n5\t81\n3\t39\n3\t50\n2\t183\n6\t181\n7\t121\n7\t31\n1\t101\n2\t148\n4\t127\n6\t138\n4\t179\n3\t172\n2\t132\n5\t30\n6\t136\n2\t163\n5\t174\n1\t161\n2\t86\n4\t160\n4\t109\n2\t112\n7\t96\n2\t60\n1\t129\n4\t129\n2\t151\n7\t46\n7\t186\n6\t90\n4\t32\n6\t191\n1\t102\n7\t113\n5\t112\n1\t199\n4\t162\n4\t169\n3\t91\n6\t68\n7\t156\n1\t163\n1\t128\n4\t178\n6\t84\n5\t102\n7\t157\n7\t83\n4\t183\n5\t76\n4\t95\n7\t99\n7\t34\n3\t92\n6\t198\n3\t160\n7\t196\n6\t138\n2\t148\n1\t91\n7\t76\n5\t192\n2\t30\n6\t96\n6\t83\n3\t30\n4\t142\n3\t96\n3\t187\n1\t92\n6\t158\n4\t142\n5\t175\n3\t176\n1\t72\n7\t165\n7\t131\n5\t195\n6\t77\n7\t84\n3\t193\n6\t71\n3\t67\n2\t114\n4\t39\n2\t164\n6\t188\n5\t169\n2\t139\n7\t170\n7\t88\n6\t79\n7\t151\n7\t153\n3\t127\n5\t125\n6\t189\n7\t131\n6\t69\n2\t56\n5\t70\n4\t44\n3\t45\n4\t151\n7\t32\n5\t122\n6\t82\n6\t144\n1\t62\n5\t158\n1\t42\n2\t96\n7\t187\n3\t57\n6\t148\n1\t181\n2\t149\n3\t40\n3\t46\n4\t171\n3\t45\n7\t77\n6\t49\n5\t36\n4\t65\n6\t76\n4\t91\n2\t59\n3\t88\n3\t145\n2\t38\n7\t165\n5\t69\n7\t151\n4\t57\n3\t81\n2\t34\n6\t176\n7\t105\n4\t116\n6\t70\n5\t143\n6\t186\n3\t41\n4\t97\n5\t117\n5\t160\n5\t152\n6\t119\n4\t61\n6\t161\n2\t96\n3\t199\n2\t173\n5\t68\n4\t99\n6\t37\n7\t81\n4\t175\n5\t102\n3\t93\n4\t192\n6\t198\n5\t100\n6\t168\n7\t140\n2\t72\n6\t75\n7\t171\n4\t159\n3\t33\n5\t176\n6\t40\n7\t177\n5\t82\n7\t86\n2\t198\n6\t168\n5\t160\n2\t37\n5\t37\n2\t80\n2\t125\n7\t139\n4\t77\n1\t78\n4\t91\n5\t125\n3\t159\n6\t178\n4\t141\n3\t95\n6\t63\n3\t110\n6\t98\n3\t115\n3\t180\n7\t85\n3\t153\n3\t165\n5\t53\n7\t156\n3\t143\n2\t31\n3\t37\n2\t175\n7\t64\n7\t163\n7\t159\n1\t109\n5\t176\n5\t77\n4\t40\n6\t120\n5\t101\n3\t56\n6\t60\n6\t127\n6\t137\n7\t174\n2\t145\n5\t169\n5\t46\n4\t104\n1\t132\n4\t140\n4\t54\n4\t179\n2\t32\n2\t56\n4\t59\n1\t199\n7\t40\n6\t87\n2\t39\n2\t96\n1\t167\n6\t135\n7\t97\n7\t153\n4\t99\n6\t179\n4\t81\n4\t86\n2\t33\n7\t135\n2\t104\n7\t193\n6\t33\n4\t45\n7\t125\n7\t76\n3\t175\n3\t94\n1\t112\n3\t108\n5\t169\n1\t93\n4\t157\n4\t104\n6\t139\n4\t196\n1\t92\n1\t105\n4\t174\n4\t189\n1\t88\n1\t93\n4\t98\n1\t71\n4\t54\n7\t72\n3\t70\n2\t141\n5\t151\n7\t162\n4\t188\n3\t106\n3\t156\n5\t121\n6\t91\n7\t63\n4\t70\n2\t116\n4\t115\n4\t31\n7\t78\n6\t181\n7\t160\n6\t88\n4\t70\n3\t90\n5\t105\n5\t176\n2\t66\n6\t178\n6\t177\n5\t166\n4\t126\n3\t40\n6\t35\n2\t161\n7\t34\n5\t142\n5\t151\n3\t197\n2\t74\n5\t104\n2\t90\n2\t193\n1\t148\n4\t63\n6\t60\n3\t192\n5\t139\n5\t126\n4\t98\n1\t199\n5\t195\n7\t180\n5\t194\n6\t136\n7\t167\n7\t101\n7\t72\n3\t84\n1\t79\n6\t88\n3\t132\n1\t103\n3\t107\n4\t93\n4\t41\n1\t152\n1\t67\n5\t73\n5\t57\n6\t151\n7\t50\n7\t125\n5\t117\n7\t135\n5\t56\n6\t56\n2\t69\n2\t115\n1\t53\n1\t52\n3\t92\n2\t115\n4\t102\n4\t113\n5\t46\n2\t43\n3\t167\n6\t35\n7\t114\n4\t54\n7\t105\n5\t97\n5\t74\n4\t159\n2\t157\n4\t127\n2\t121\n7\t72\n6\t117\n5\t76\n5\t183\n4\t87\n6\t43\n5\t55\n5\t38\n7\t54\n5\t106\n5\t193\n5\t52\n6\t177\n5\t151\n4\t194\n1\t102\n3\t200\n4\t37\n7\t172\n2\t46\n6\t105\n1\t117\n2\t133\n3\t184\n6\t134\n2\t106\n1\t119\n4\t69\n5\t73\n3\t177\n1\t52\n4\t146\n2\t155\n5\t39\n1\t72\n7\t108\n7\t178\n4\t57\n4\t112\n4\t129\n6\t178\n1\t174\n7\t132\n4\t148\n4\t194\n2\t155\n3\t40\n6\t65\n6\t36\n4\t73\n2\t196\n7\t100\n1\t113\n7\t139\n3\t100\n5\t90\n2\t106\n1\t104\n1\t42\n3\t127\n2\t45\n7\t142\n2\t187\n1\t179\n7\t163\n1\t58\n6\t92\n7\t120\n4\t110\n6\t185\n5\t103\n7\t44\n7\t183\n5\t44\n5\t77\n5\t40\n7\t92\n7\t177\n6\t59\n2\t172\n7\t70\n5\t149\n4\t110\n4\t132\n1\t119\n2\t133\n3\t58\n3\t195\n7\t153\n7\t152\n3\t61\n1\t75\n3\t110\n1\t194\n1\t177\n5\t181\n1\t131\n3\t112\n5\t184\n6\t177\n1\t171\n4\t152\n1\t165\n1\t194\n5\t141\n7\t121\n5\t77\n6\t130\n2\t73\n7\t195\n2\t89\n6\t183\n4\t181\n2\t82\n7\t84\n6\t100\n3\t135\n6\t34\n2\t192\n3\t187\n2\t112\n7\t129\n3\t183\n1\t178\n1\t180\n7\t180\n3\t152\n3\t62\n2\t89\n7\t146\n6\t165\n6\t35\n5\t142\n2\t92\n7\t84\n5\t176\n5\t76\n1\t117\n3\t38\n1\t75\n4\t152\n6\t137\n5\t56\n4\t171\n4\t65\n3\t93\n5\t83\n6\t38\n2\t35\n5\t111\n1\t150\n5\t188\n1\t49\n1\t145\n2\t65\n5\t96\n2\t147\n3\t165\n2\t182\n4\t84\n5\t167\n1\t121\n1\t53\n3\t89\n2\t31\n4\t153\n6\t161\n6\t139\n3\t167\n3\t53\n4\t117\n7\t180\n3\t38\n5\t120\n5\t119\n7\t165\n2\t130\n3\t113\n3\t199\n2\t34\n5\t102\n3\t183\n1\t121\n7\t62\n2\t143\n6\t148\n2\t137\n2\t127\n1\t184\n6\t182\n5\t159\n6\t169\n7\t73\n1\t197\n5\t51\n4\t190\n7\t70\n4\t48\n1\t182\n4\t123\n1\t67\n7\t188\n5\t106\n7\t184\n4\t109\n5\t170\n2\t174\n4\t88\n6\t99\n5\t36\n3\t82\n7\t109\n2\t153\n4\t128\n3\t152\n7\t49\n7\t129\n5\t38\n1\t139\n6\t190\n1\t151\n6\t97\n3\t75\n6\t95\n2\t56\n7\t103\n2\t116\n2\t138\n4\t91\n5\t179\n6\t158\n6\t56\n4\t113\n4\t46\n7\t117\n6\t162\n4\t71\n4\t150\n4\t170\n3\t104\n3\t127\n7\t146\n4\t178\n6\t121\n5\t51\n1\t188\n4\t192\n1\t153\n5\t197\n2\t151\n6\t95\n5\t53\n3\t94\n1\t190\n5\t31\n1\t144\n6\t109\n5\t109\n2\t200\n3\t131\n2\t35\n7\t117\n6\t156\n1\t151\n6\t175\n7\t68\n6\t33\n2\t86\n3\t59\n3\t49\n6\t108\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/longruntest4.txt",
    "content": "1000 1500\n6\t152\n3\t34\n1\t151\n6\t198\n5\t126\n7\t133\n2\t167\n6\t114\n7\t165\n2\t144\n7\t55\n1\t50\n7\t174\n6\t98\n1\t151\n7\t87\n4\t37\n2\t195\n5\t45\n1\t127\n1\t92\n1\t169\n1\t36\n3\t171\n1\t131\n2\t128\n7\t137\n6\t58\n3\t162\n3\t170\n3\t174\n6\t113\n2\t179\n5\t151\n7\t30\n3\t152\n3\t162\n1\t148\n6\t157\n7\t70\n4\t58\n6\t181\n4\t100\n4\t134\n5\t193\n2\t39\n3\t152\n6\t139\n3\t182\n4\t40\n2\t157\n7\t117\n6\t70\n5\t36\n5\t94\n2\t81\n3\t103\n4\t140\n1\t110\n6\t31\n6\t35\n5\t171\n4\t136\n2\t46\n1\t41\n3\t31\n7\t40\n4\t130\n4\t57\n2\t164\n2\t144\n6\t155\n5\t79\n4\t188\n6\t167\n1\t193\n7\t64\n2\t92\n4\t68\n4\t149\n3\t62\n1\t111\n1\t181\n2\t196\n3\t67\n7\t94\n7\t49\n5\t185\n7\t84\n5\t150\n4\t126\n2\t86\n2\t107\n5\t177\n2\t153\n5\t127\n4\t179\n7\t74\n7\t142\n5\t167\n2\t132\n3\t99\n2\t188\n2\t58\n3\t69\n1\t133\n3\t51\n4\t167\n1\t77\n7\t182\n2\t55\n2\t60\n3\t57\n7\t66\n3\t104\n2\t161\n1\t81\n6\t108\n7\t44\n6\t150\n1\t195\n7\t44\n7\t85\n4\t67\n2\t171\n7\t136\n3\t50\n2\t129\n6\t119\n3\t157\n7\t79\n3\t143\n4\t80\n6\t61\n2\t52\n1\t172\n4\t62\n3\t101\n3\t83\n6\t164\n4\t168\n6\t74\n1\t106\n3\t75\n3\t115\n6\t122\n3\t134\n2\t54\n5\t145\n6\t73\n6\t40\n7\t112\n3\t97\n6\t129\n1\t107\n1\t180\n2\t35\n6\t40\n2\t200\n4\t77\n5\t127\n2\t119\n7\t90\n1\t71\n3\t149\n2\t120\n4\t132\n5\t119\n5\t136\n7\t115\n5\t123\n5\t161\n5\t155\n2\t69\n7\t169\n4\t80\n2\t167\n5\t68\n2\t79\n6\t154\n7\t146\n4\t151\n2\t174\n1\t165\n4\t63\n3\t169\n7\t136\n3\t120\n4\t182\n4\t96\n1\t118\n7\t63\n3\t163\n3\t190\n6\t90\n6\t117\n5\t157\n6\t87\n7\t149\n6\t125\n6\t135\n2\t145\n7\t110\n2\t148\n4\t35\n2\t50\n7\t200\n5\t77\n2\t44\n6\t97\n7\t187\n2\t100\n1\t127\n6\t34\n2\t57\n1\t44\n5\t146\n2\t67\n3\t72\n3\t172\n3\t160\n6\t139\n3\t64\n3\t76\n7\t179\n5\t143\n6\t56\n3\t55\n4\t114\n6\t139\n6\t97\n2\t142\n2\t187\n1\t53\n6\t30\n5\t131\n3\t197\n2\t113\n2\t191\n2\t42\n4\t112\n6\t175\n4\t44\n2\t89\n5\t77\n5\t64\n7\t65\n6\t80\n1\t164\n7\t46\n1\t36\n1\t59\n5\t116\n6\t111\n4\t68\n7\t151\n5\t147\n2\t49\n7\t91\n4\t69\n3\t68\n5\t155\n5\t122\n6\t89\n7\t200\n6\t92\n7\t31\n3\t99\n6\t45\n1\t152\n6\t102\n3\t132\n5\t163\n3\t166\n7\t64\n1\t135\n1\t154\n4\t158\n1\t71\n4\t121\n4\t60\n5\t119\n7\t135\n5\t100\n6\t160\n6\t44\n6\t66\n3\t45\n1\t73\n4\t64\n1\t37\n5\t89\n2\t74\n1\t164\n5\t189\n3\t185\n3\t127\n3\t177\n7\t127\n7\t196\n4\t99\n5\t195\n7\t62\n3\t74\n5\t110\n1\t137\n1\t114\n2\t75\n2\t67\n4\t189\n5\t41\n3\t114\n3\t193\n5\t62\n3\t33\n1\t100\n7\t110\n3\t150\n3\t121\n6\t36\n5\t174\n3\t120\n6\t139\n2\t192\n5\t74\n1\t161\n2\t168\n2\t135\n1\t173\n5\t147\n5\t59\n5\t35\n3\t108\n1\t45\n2\t64\n2\t99\n3\t63\n3\t176\n4\t119\n2\t171\n5\t135\n4\t132\n3\t128\n4\t38\n3\t146\n7\t182\n7\t177\n3\t36\n1\t128\n2\t143\n1\t159\n1\t46\n6\t40\n5\t30\n5\t71\n5\t140\n5\t100\n3\t165\n5\t86\n1\t144\n4\t184\n2\t30\n7\t54\n6\t148\n5\t172\n4\t133\n6\t147\n1\t200\n2\t58\n7\t85\n5\t32\n2\t198\n2\t163\n6\t53\n7\t44\n7\t33\n6\t110\n1\t187\n4\t127\n2\t196\n1\t131\n3\t119\n6\t179\n6\t148\n1\t44\n4\t194\n4\t84\n2\t80\n6\t155\n5\t113\n6\t175\n2\t89\n3\t113\n2\t34\n6\t60\n3\t133\n2\t136\n3\t103\n4\t63\n1\t94\n5\t37\n1\t134\n3\t92\n6\t194\n3\t163\n2\t148\n4\t199\n3\t138\n7\t49\n2\t57\n7\t166\n5\t176\n7\t154\n2\t68\n4\t186\n6\t95\n4\t175\n3\t90\n3\t124\n1\t45\n4\t197\n6\t131\n5\t55\n5\t68\n3\t33\n2\t111\n7\t40\n7\t41\n7\t61\n3\t54\n3\t180\n5\t138\n7\t134\n3\t39\n4\t124\n4\t160\n6\t40\n7\t154\n5\t96\n2\t31\n3\t88\n7\t190\n7\t197\n3\t133\n5\t184\n6\t36\n3\t43\n4\t45\n3\t49\n6\t192\n1\t59\n4\t59\n4\t105\n1\t192\n2\t145\n4\t55\n5\t191\n4\t30\n3\t139\n7\t97\n3\t112\n4\t39\n6\t182\n4\t70\n7\t187\n7\t133\n6\t92\n2\t157\n6\t79\n2\t33\n7\t118\n5\t176\n5\t102\n3\t138\n6\t115\n7\t195\n3\t74\n5\t118\n2\t200\n1\t135\n7\t73\n2\t126\n4\t161\n3\t144\n4\t99\n5\t87\n6\t33\n6\t56\n1\t104\n7\t119\n5\t195\n2\t190\n4\t184\n2\t130\n5\t129\n5\t153\n1\t104\n1\t140\n3\t64\n2\t187\n3\t91\n2\t149\n7\t44\n3\t39\n1\t156\n7\t178\n2\t55\n3\t74\n4\t166\n7\t149\n3\t45\n2\t86\n5\t35\n4\t76\n1\t58\n7\t140\n1\t132\n3\t114\n6\t145\n4\t161\n2\t79\n1\t75\n4\t74\n1\t180\n1\t178\n7\t194\n4\t119\n2\t157\n5\t118\n2\t62\n5\t136\n4\t43\n4\t62\n1\t44\n5\t115\n3\t88\n5\t48\n6\t52\n1\t111\n3\t34\n3\t83\n1\t67\n1\t119\n7\t55\n1\t156\n4\t177\n7\t192\n5\t126\n4\t143\n4\t82\n5\t65\n7\t191\n4\t93\n5\t93\n2\t88\n7\t121\n6\t112\n2\t58\n2\t197\n3\t65\n6\t104\n1\t196\n7\t191\n3\t122\n6\t59\n4\t186\n6\t198\n5\t94\n4\t60\n4\t41\n7\t175\n1\t179\n7\t150\n1\t200\n3\t111\n7\t90\n2\t144\n6\t73\n4\t57\n1\t136\n6\t173\n7\t132\n6\t152\n4\t132\n3\t59\n6\t46\n2\t129\n7\t40\n6\t92\n1\t139\n6\t120\n6\t156\n5\t134\n3\t181\n1\t114\n2\t192\n2\t175\n7\t149\n4\t145\n1\t71\n3\t128\n7\t154\n7\t91\n4\t179\n4\t196\n3\t191\n6\t94\n4\t168\n7\t197\n4\t142\n5\t117\n4\t171\n2\t141\n7\t86\n3\t173\n2\t188\n5\t170\n4\t60\n3\t173\n2\t156\n1\t105\n1\t43\n4\t156\n3\t66\n3\t103\n6\t56\n1\t106\n5\t38\n5\t59\n3\t76\n5\t121\n6\t199\n2\t141\n4\t198\n2\t32\n3\t108\n1\t128\n1\t175\n4\t42\n2\t126\n4\t136\n3\t63\n4\t80\n2\t80\n2\t83\n2\t75\n2\t153\n3\t63\n3\t193\n5\t164\n3\t44\n1\t171\n7\t106\n4\t196\n2\t199\n3\t108\n5\t89\n1\t105\n2\t117\n3\t78\n2\t45\n5\t100\n2\t51\n6\t30\n2\t82\n1\t133\n1\t157\n7\t107\n6\t178\n4\t173\n4\t161\n4\t194\n5\t197\n1\t178\n3\t133\n4\t165\n4\t125\n6\t179\n2\t158\n3\t163\n2\t75\n3\t60\n7\t68\n5\t100\n4\t68\n3\t112\n6\t192\n5\t36\n4\t166\n6\t200\n1\t120\n7\t200\n4\t111\n3\t99\n2\t125\n7\t31\n1\t56\n6\t72\n7\t60\n7\t30\n2\t41\n2\t164\n7\t77\n1\t146\n5\t129\n7\t67\n7\t156\n2\t167\n6\t184\n3\t174\n2\t179\n1\t161\n1\t64\n1\t168\n7\t200\n5\t104\n1\t73\n4\t197\n5\t154\n6\t82\n2\t122\n2\t190\n4\t115\n1\t94\n3\t140\n4\t174\n4\t61\n2\t140\n1\t145\n6\t89\n1\t155\n6\t124\n2\t91\n7\t106\n2\t78\n3\t100\n5\t154\n6\t60\n4\t155\n5\t162\n6\t166\n5\t108\n5\t90\n5\t187\n6\t173\n7\t65\n3\t149\n7\t188\n7\t100\n2\t73\n4\t94\n1\t91\n5\t194\n6\t123\n5\t198\n7\t154\n3\t100\n5\t176\n7\t186\n2\t159\n6\t50\n2\t174\n4\t80\n1\t83\n7\t178\n6\t191\n2\t194\n1\t142\n7\t80\n5\t147\n7\t171\n2\t94\n3\t160\n3\t35\n6\t193\n5\t165\n6\t97\n5\t90\n2\t139\n5\t142\n6\t108\n1\t143\n3\t70\n2\t47\n2\t179\n6\t151\n4\t96\n6\t31\n4\t130\n4\t192\n3\t115\n5\t44\n5\t33\n5\t110\n3\t57\n4\t105\n7\t45\n2\t107\n5\t174\n4\t57\n1\t108\n6\t90\n1\t46\n6\t116\n6\t56\n1\t151\n7\t43\n3\t138\n1\t57\n1\t124\n2\t94\n6\t98\n3\t168\n6\t97\n2\t94\n6\t64\n3\t158\n6\t124\n4\t121\n1\t183\n2\t96\n2\t155\n4\t155\n5\t116\n3\t123\n4\t79\n2\t132\n4\t98\n5\t65\n6\t131\n1\t160\n6\t172\n7\t145\n3\t44\n2\t181\n3\t33\n7\t178\n4\t190\n7\t34\n7\t161\n5\t69\n1\t37\n1\t138\n4\t42\n5\t112\n4\t101\n2\t187\n7\t167\n3\t177\n1\t192\n6\t90\n2\t177\n2\t56\n4\t34\n6\t136\n7\t108\n1\t54\n3\t185\n1\t173\n1\t77\n5\t116\n5\t89\n5\t36\n2\t161\n7\t63\n7\t42\n6\t180\n3\t193\n6\t109\n7\t79\n7\t192\n5\t51\n1\t181\n6\t165\n5\t115\n5\t59\n4\t195\n3\t113\n1\t52\n7\t94\n6\t59\n6\t41\n1\t56\n3\t151\n5\t146\n7\t92\n6\t30\n7\t59\n2\t102\n4\t33\n5\t114\n7\t110\n3\t78\n3\t144\n5\t175\n2\t87\n1\t162\n3\t185\n7\t173\n5\t40\n6\t66\n3\t148\n4\t184\n6\t139\n5\t172\n5\t103\n5\t162\n3\t171\n6\t61\n1\t131\n6\t185\n2\t50\n7\t104\n1\t80\n4\t52\n7\t36\n2\t106\n3\t172\n4\t172\n2\t76\n7\t50\n4\t121\n6\t63\n3\t94\n2\t97\n4\t119\n2\t161\n7\t78\n5\t86\n6\t86\n7\t167\n4\t58\n2\t145\n2\t190\n2\t113\n5\t125\n1\t198\n4\t81\n1\t155\n4\t113\n4\t75\n1\t143\n2\t143\n5\t187\n6\t184\n6\t134\n2\t141\n5\t130\n5\t58\n5\t180\n2\t174\n7\t176\n3\t188\n5\t57\n7\t53\n3\t56\n4\t53\n7\t183\n7\t160\n2\t170\n6\t185\n5\t42\n4\t124\n6\t182\n7\t197\n4\t96\n4\t125\n7\t159\n6\t79\n6\t172\n7\t58\n6\t145\n7\t107\n3\t115\n2\t139\n5\t134\n3\t135\n6\t65\n5\t119\n2\t88\n2\t71\n3\t104\n7\t172\n5\t84\n7\t105\n1\t89\n7\t107\n6\t44\n7\t33\n1\t97\n2\t35\n3\t132\n4\t36\n6\t63\n1\t178\n4\t160\n3\t35\n5\t152\n7\t117\n3\t47\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/longruntest5.txt",
    "content": "1000 3000\n2\t172\n1\t74\n2\t95\n3\t160\n1\t41\n1\t41\n4\t98\n2\t131\n2\t52\n7\t195\n5\t129\n5\t122\n7\t171\n3\t71\n3\t89\n2\t73\n4\t52\n2\t128\n7\t179\n3\t113\n6\t199\n6\t187\n3\t164\n6\t77\n7\t200\n6\t127\n5\t184\n1\t98\n2\t104\n7\t129\n4\t128\n6\t111\n6\t110\n6\t186\n7\t145\n2\t110\n1\t190\n4\t57\n4\t169\n2\t169\n2\t33\n1\t99\n1\t154\n3\t176\n4\t69\n1\t117\n7\t33\n1\t53\n6\t152\n3\t72\n7\t104\n2\t38\n2\t101\n2\t128\n2\t101\n5\t151\n3\t115\n7\t117\n6\t94\n3\t128\n2\t65\n5\t30\n6\t30\n4\t151\n6\t175\n5\t45\n6\t75\n6\t55\n1\t69\n5\t41\n1\t88\n6\t89\n6\t115\n2\t114\n2\t153\n6\t77\n5\t182\n2\t91\n6\t49\n4\t140\n6\t107\n6\t106\n6\t154\n4\t50\n6\t139\n6\t93\n1\t34\n1\t168\n1\t107\n5\t76\n4\t72\n1\t126\n4\t180\n4\t126\n5\t77\n3\t124\n5\t131\n5\t58\n7\t91\n3\t164\n3\t183\n4\t133\n1\t165\n3\t75\n5\t104\n1\t74\n5\t162\n6\t86\n7\t190\n5\t93\n3\t137\n1\t97\n5\t86\n4\t195\n1\t159\n1\t200\n2\t64\n3\t142\n3\t109\n6\t166\n7\t98\n6\t155\n4\t186\n4\t75\n3\t199\n2\t100\n7\t97\n6\t130\n7\t165\n6\t141\n5\t72\n3\t130\n4\t67\n5\t146\n6\t101\n5\t90\n2\t60\n2\t181\n5\t41\n1\t43\n5\t118\n3\t85\n2\t94\n2\t57\n3\t59\n2\t114\n5\t113\n5\t152\n1\t83\n7\t139\n5\t169\n2\t45\n2\t158\n5\t62\n7\t75\n7\t107\n1\t65\n7\t189\n3\t109\n1\t165\n5\t116\n6\t161\n2\t137\n6\t193\n4\t143\n7\t80\n5\t132\n1\t98\n6\t92\n3\t173\n5\t131\n1\t174\n2\t41\n6\t76\n7\t65\n3\t135\n2\t56\n5\t134\n5\t70\n2\t194\n3\t38\n3\t57\n4\t57\n6\t162\n7\t90\n1\t116\n6\t190\n5\t119\n4\t114\n4\t185\n4\t52\n3\t162\n6\t60\n3\t118\n7\t155\n7\t51\n6\t114\n2\t95\n6\t111\n6\t139\n4\t149\n7\t98\n3\t40\n2\t79\n2\t109\n3\t125\n3\t63\n4\t87\n4\t76\n2\t62\n4\t131\n1\t32\n6\t174\n7\t91\n3\t60\n1\t171\n3\t107\n2\t167\n4\t171\n4\t41\n6\t118\n4\t101\n2\t103\n7\t153\n4\t127\n6\t128\n2\t54\n7\t180\n7\t118\n1\t147\n5\t79\n2\t72\n3\t140\n5\t128\n4\t36\n4\t157\n2\t125\n4\t196\n2\t71\n3\t197\n3\t179\n1\t52\n2\t195\n5\t196\n4\t85\n3\t89\n5\t140\n5\t70\n2\t41\n3\t124\n7\t76\n1\t59\n1\t98\n4\t34\n3\t46\n2\t126\n7\t90\n6\t67\n6\t63\n6\t81\n2\t103\n3\t34\n7\t55\n1\t180\n7\t112\n3\t80\n6\t40\n1\t127\n3\t86\n4\t40\n2\t176\n1\t119\n4\t149\n3\t122\n2\t189\n6\t186\n2\t189\n6\t137\n3\t75\n5\t112\n3\t83\n1\t35\n1\t199\n3\t66\n7\t117\n5\t190\n4\t40\n5\t106\n3\t37\n3\t136\n6\t156\n3\t150\n3\t57\n3\t59\n7\t122\n1\t184\n7\t35\n1\t77\n4\t83\n1\t139\n5\t135\n6\t170\n4\t200\n5\t197\n1\t30\n7\t168\n3\t97\n2\t105\n7\t162\n3\t182\n3\t69\n7\t156\n5\t106\n4\t146\n7\t34\n3\t172\n4\t31\n7\t145\n5\t31\n2\t86\n4\t136\n2\t106\n7\t37\n7\t71\n2\t104\n4\t55\n5\t63\n7\t79\n5\t72\n6\t35\n5\t83\n3\t40\n5\t40\n5\t193\n2\t154\n3\t183\n5\t62\n6\t80\n7\t34\n4\t73\n4\t165\n2\t116\n3\t174\n6\t77\n7\t157\n7\t127\n3\t114\n6\t78\n2\t184\n4\t50\n5\t73\n4\t76\n5\t138\n7\t51\n2\t75\n1\t182\n3\t164\n4\t77\n4\t73\n2\t189\n7\t108\n3\t128\n4\t92\n7\t40\n2\t82\n1\t132\n5\t186\n6\t108\n7\t104\n7\t137\n2\t36\n6\t111\n7\t131\n3\t145\n7\t112\n4\t146\n2\t119\n1\t49\n7\t194\n3\t47\n5\t38\n2\t92\n6\t162\n5\t100\n5\t56\n6\t182\n1\t186\n6\t139\n4\t137\n3\t47\n7\t105\n6\t175\n1\t39\n5\t57\n6\t90\n4\t105\n1\t153\n7\t55\n3\t50\n1\t181\n2\t39\n3\t138\n5\t163\n6\t36\n7\t130\n6\t42\n3\t147\n1\t48\n3\t93\n2\t71\n2\t158\n3\t58\n4\t48\n5\t31\n5\t148\n6\t68\n6\t151\n4\t180\n1\t105\n2\t185\n3\t140\n4\t138\n7\t57\n3\t79\n3\t190\n4\t135\n6\t135\n5\t62\n1\t127\n7\t49\n3\t46\n5\t144\n2\t53\n4\t62\n4\t44\n7\t88\n6\t91\n2\t190\n1\t194\n4\t195\n5\t102\n5\t101\n1\t75\n5\t57\n2\t108\n6\t134\n6\t195\n1\t94\n1\t185\n7\t110\n6\t107\n1\t51\n5\t151\n7\t94\n3\t101\n5\t179\n6\t58\n6\t126\n2\t128\n3\t49\n6\t109\n2\t121\n2\t64\n2\t145\n3\t153\n5\t61\n5\t75\n7\t60\n7\t33\n1\t72\n7\t86\n6\t122\n7\t172\n3\t153\n2\t160\n4\t140\n1\t173\n3\t121\n6\t49\n4\t101\n6\t117\n2\t38\n3\t107\n5\t115\n5\t147\n1\t173\n5\t66\n4\t198\n5\t124\n6\t80\n6\t79\n2\t91\n3\t126\n2\t38\n1\t111\n6\t196\n1\t187\n1\t114\n6\t105\n4\t126\n4\t150\n4\t61\n6\t86\n3\t33\n6\t136\n6\t39\n2\t118\n2\t91\n7\t101\n6\t93\n1\t39\n6\t121\n1\t168\n5\t71\n5\t61\n2\t115\n5\t64\n3\t151\n6\t197\n5\t174\n1\t100\n6\t185\n5\t137\n6\t41\n7\t105\n6\t146\n3\t45\n4\t52\n7\t79\n2\t141\n7\t145\n1\t65\n4\t107\n6\t66\n7\t81\n4\t157\n3\t198\n6\t80\n2\t72\n7\t116\n7\t102\n3\t148\n1\t109\n5\t141\n2\t148\n3\t125\n3\t145\n5\t44\n2\t167\n4\t196\n1\t166\n1\t133\n7\t173\n5\t166\n1\t65\n4\t31\n1\t72\n4\t174\n5\t36\n2\t70\n5\t42\n3\t148\n7\t193\n3\t38\n6\t143\n7\t175\n4\t90\n5\t91\n3\t172\n3\t183\n5\t146\n5\t165\n3\t64\n3\t186\n4\t87\n2\t199\n5\t127\n1\t53\n3\t184\n3\t137\n2\t38\n1\t191\n5\t39\n1\t110\n1\t156\n3\t139\n4\t35\n7\t190\n6\t41\n1\t159\n7\t31\n7\t152\n5\t129\n6\t135\n6\t118\n2\t168\n5\t160\n5\t187\n5\t171\n6\t140\n3\t172\n5\t190\n5\t149\n3\t83\n5\t176\n2\t165\n1\t43\n2\t169\n4\t138\n5\t194\n7\t197\n2\t111\n4\t101\n2\t157\n5\t94\n4\t169\n3\t189\n5\t174\n5\t168\n3\t193\n2\t148\n4\t128\n7\t135\n7\t198\n3\t76\n6\t106\n3\t128\n2\t74\n6\t62\n2\t192\n2\t70\n4\t30\n7\t180\n1\t94\n4\t80\n4\t149\n4\t170\n1\t164\n4\t101\n7\t190\n4\t118\n3\t137\n4\t40\n2\t84\n4\t172\n3\t75\n4\t90\n2\t102\n1\t152\n5\t192\n5\t57\n6\t77\n4\t147\n5\t131\n1\t96\n6\t41\n5\t31\n3\t112\n6\t176\n6\t187\n6\t55\n4\t103\n3\t101\n1\t114\n3\t79\n7\t34\n7\t191\n1\t153\n5\t185\n5\t170\n6\t69\n2\t89\n5\t174\n6\t88\n4\t121\n1\t115\n6\t34\n1\t46\n5\t123\n7\t143\n5\t95\n4\t166\n7\t159\n3\t118\n1\t61\n7\t46\n7\t127\n2\t56\n7\t52\n2\t31\n6\t167\n1\t78\n4\t102\n4\t94\n2\t72\n5\t95\n1\t107\n6\t147\n1\t34\n6\t84\n5\t129\n5\t151\n6\t126\n1\t130\n5\t112\n7\t154\n1\t109\n4\t37\n7\t62\n6\t136\n6\t94\n3\t173\n7\t128\n2\t68\n2\t83\n2\t125\n7\t102\n4\t138\n2\t46\n7\t72\n4\t52\n6\t43\n5\t172\n4\t134\n6\t98\n1\t49\n1\t172\n1\t199\n4\t113\n1\t168\n4\t180\n7\t142\n7\t101\n3\t86\n6\t153\n7\t70\n2\t103\n2\t102\n3\t40\n1\t194\n7\t67\n4\t131\n4\t108\n3\t103\n1\t41\n7\t152\n7\t80\n2\t85\n3\t147\n4\t176\n4\t143\n1\t81\n1\t67\n7\t54\n7\t153\n5\t107\n3\t197\n6\t33\n4\t78\n3\t88\n3\t94\n4\t72\n1\t192\n6\t68\n1\t67\n4\t129\n7\t78\n3\t114\n6\t141\n4\t93\n2\t58\n2\t91\n4\t134\n2\t32\n3\t35\n4\t100\n4\t64\n3\t131\n1\t50\n5\t76\n5\t46\n5\t70\n4\t75\n1\t103\n7\t36\n3\t193\n6\t135\n3\t103\n1\t165\n3\t143\n7\t177\n3\t141\n3\t76\n5\t100\n2\t54\n5\t84\n3\t48\n2\t183\n4\t136\n7\t161\n6\t106\n2\t91\n3\t165\n6\t134\n6\t67\n6\t183\n3\t144\n6\t47\n4\t185\n2\t123\n3\t131\n2\t76\n7\t37\n7\t33\n6\t165\n6\t152\n1\t165\n3\t112\n7\t156\n6\t87\n1\t157\n6\t171\n2\t124\n6\t79\n2\t144\n2\t126\n6\t140\n6\t163\n5\t76\n6\t96\n4\t197\n6\t51\n7\t30\n4\t92\n2\t165\n7\t126\n7\t169\n6\t160\n7\t118\n2\t98\n3\t42\n3\t55\n1\t191\n6\t74\n1\t108\n4\t52\n2\t124\n6\t159\n5\t99\n3\t129\n1\t83\n4\t82\n5\t32\n6\t122\n4\t123\n1\t167\n1\t82\n4\t81\n3\t146\n2\t107\n6\t169\n3\t98\n4\t102\n5\t185\n2\t118\n4\t120\n7\t113\n2\t55\n6\t138\n4\t191\n1\t142\n5\t77\n6\t171\n1\t189\n3\t130\n1\t106\n2\t117\n1\t141\n3\t199\n7\t52\n2\t129\n4\t32\n4\t186\n1\t166\n1\t114\n4\t193\n7\t50\n3\t30\n6\t103\n5\t122\n3\t189\n5\t128\n5\t171\n1\t145\n3\t83\n2\t129\n4\t64\n6\t62\n5\t103\n1\t193\n4\t183\n2\t175\n6\t104\n1\t48\n3\t163\n5\t180\n7\t170\n2\t50\n1\t31\n4\t137\n2\t172\n1\t144\n1\t174\n7\t35\n7\t165\n3\t151\n1\t193\n2\t176\n1\t72\n4\t146\n1\t188\n7\t37\n4\t147\n2\t79\n2\t135\n6\t111\n2\t73\n5\t174\n5\t119\n6\t87\n4\t41\n1\t45\n7\t34\n5\t150\n6\t53\n3\t116\n2\t59\n1\t109\n1\t192\n5\t71\n1\t36\n5\t103\n5\t113\n1\t87\n1\t31\n2\t155\n2\t31\n1\t137\n7\t130\n1\t125\n7\t134\n6\t129\n7\t148\n3\t31\n3\t36\n6\t91\n2\t152\n6\t39\n7\t98\n7\t33\n6\t146\n6\t122\n3\t82\n2\t95\n1\t114\n1\t152\n4\t169\n3\t178\n1\t165\n4\t140\n3\t39\n4\t169\n5\t74\n7\t49\n4\t117\n3\t144\n3\t144\n5\t60\n5\t161\n5\t177\n3\t160\n4\t49\n3\t122\n7\t118\n6\t78\n7\t194\n5\t74\n1\t92\n6\t59\n2\t79\n5\t146\n5\t30\n2\t59\n7\t126\n7\t143\n4\t46\n3\t194\n1\t129\n5\t126\n7\t145\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/test01_03.txt",
    "content": "26 45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n1\t15\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/test02_03.txt",
    "content": "26 45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n2\t30\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/test03.1_03.txt",
    "content": "26 47\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n2\t30\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/test03_03.txt",
    "content": "26 46\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n2\t30\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/test04_03.txt",
    "content": "26 46\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t44\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n2\t30\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/handmade_tests/test05_03.txt",
    "content": "25 46\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t61\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/run_commands.sh",
    "content": "#!/bin/sh\n\nWARMUP=50\nRUNS=100\nSUM_MEANS=0\nFILE_COUNT=0\nMFNL=0           # Max FileName Length Start\n\nfor file in examples/*\ndo\n  filename=$(basename \"$file\")\n  len=$(echo -n \"$filename\" | wc -c)\n  if [ \"$len\" -gt \"$MFNL\" ]; then\n    MFNL=$len\n  fi\ndone\n\n# Build the project\ncargo build --release --quiet\n\nexport BC_LINE_LENGTH=0\nclear\n\necho -e \"\\n\\nRodará um (Hyperfine) Benchmark de $RUNS runs para cada arquivo\"\necho -e \"Depois pego as médias numa jq, e calculo ao final a soma das médias\"\necho -e \"Isso foi feito para facilitar a execução e visualização dos resultados\\n\\n\"\n\nprintf \"%-${MFNL}s  %s \\t %s \\n\" \"FileName\" \"Respostas\" \"Runtime\"\nfor file in examples/*\ndo\n  result=$(hyperfine --warmup \"$WARMUP\" --runs \"$RUNS\" \"./target/release/problema_1 $file\" --export-json /tmp/hyperfine_results.json 2>/dev/null)\n  \n  output=$(./target/release/problema_1 \"$file\")\n  filename=$(basename \"$file\")\n  mean=$(jq -r '.results | .[0].mean' /tmp/hyperfine_results.json)\n  \n  formatted_mean=$(echo \"$mean\" | awk '{printf \"%.9f\", $1}')\n  SUM_MEANS=$(awk \"BEGIN {print $SUM_MEANS + $formatted_mean}\")\n  FILE_COUNT=$((FILE_COUNT + 1))\n  \n  printf \"%-${MFNL}s $output \\t $formatted_mean s\\n\" \"$filename\"\ndone\n\nAVERAGE_MEAN=$(echo \"scale=9; $SUM_MEANS / $FILE_COUNT\" | bc)\n\nTOTAL_RUNTIME=$(printf \"%.9f\" \"$SUM_MEANS\")\nAVERAGE_MEAN=$(printf \"%.9f\" \"$AVERAGE_MEAN\")\n\necho -e \"\\nTotal Runtime:   \\t\\t $TOTAL_RUNTIME s\\n\"\necho -e \"\\nAvarage Runtime: \\t\\t $AVERAGE_MEAN s\\n\\n\""
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_1/Rust/src/main.rs",
    "content": "use std::env;\nuse std::fs::File;\nuse std::io::{BufRead, BufReader};\n\nfn knapsack(space: i64, array: &[(i64, i64, f64)]) -> i64 {\n    let n = array.len();\n    let mut dp = vec![0; (space + 1) as usize];\n\n    for i in 0..n {\n        let (wi, vi, _) = array[i];\n        for j in (wi..=space).rev() {\n            dp[j as usize] = dp[j as usize].max(vi + dp[(j - wi) as usize]);\n        }\n    }\n\n    dp[space as usize]\n}\n\nfn execute_algorithm(file_path: &str) -> i64 {\n    let file = File::open(file_path).unwrap();\n    let reader = BufReader::new(file);\n\n    let mut lines = reader.lines();\n    let first_line = lines.next().unwrap().unwrap();\n    let mut values = first_line.split_whitespace().map(|x| x.parse::<i64>().unwrap());\n    let _n = values.next().unwrap();\n    let w = values.next().unwrap();\n\n    let mut file_array = Vec::new();\n\n    for line in lines {\n        let mut row: Vec<f64> = line.unwrap()\n            .split_whitespace()\n            .map(|x| x.parse::<f64>().unwrap())\n            .collect();\n        let ratio = row[1] / row[0];\n        row.push(ratio);\n        file_array.push((row[0] as i64, row[1] as i64, ratio));\n    }\n\n    knapsack(w, &file_array)\n}\n\nfn main() {\n    let args: Vec<String> = env::args().collect();\n    let file_path = &args[1];\n    println!(\"{:>10}\", execute_algorithm(file_path));\n}"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_2/Python/Dockerfile",
    "content": "FROM python:3.11.7-alpine3.18\n\n# Install the hyperfine package and networkx\nRUN apk --no-cache add hyperfine jq \\\n    && pip install networkx==3.2\n\nWORKDIR /app\nCOPY . /app\n\n# Make the script executable\nRUN chmod +x /app/runtime.sh\n\n# Run the script as the default command\nCMD [\"/app/runtime.sh\"]\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_2/Python/ReadMe.md",
    "content": "# Requisitos\n- ***Docker***\n\n# Como Rodar\n### PowerShell(MS)  *ou*  Shell(Linux)\n> Execute uma linha de cada vez no console, sempre esperando a anterior terminar de executar\n`e não esqueça de escrever o \".\"`\n\n1. Ir ao **diretório** do *Dockerfile*\n- **PowerShell**/***Bash***\n```PowerShell\ncd Path/to/submissions/gabrielng-rj99/Problema_2/Python/\n```\n\n\n2. *Gerar* a **Imagem** do *Dockerfile*\n- **PowerShell**/***Bash***\n```PowerShell\ndocker build -t problem_2:gabrielng-rj99 . \n```\n\n3. *Gerar* um **conteiner** da *imagem* e rodá-lo\n- **PowerShell**/***Bash***\n```PowerShell\ndocker run --cpus=2 --memory=2g --name gng-rj99_p2 problem_2:gabrielng-rj99\n```\n\n- **Resultado Esperado(Print):**\n\n![ExpectedShellPrint](./print.png)\n\n\n4. Caso queira rodar o conteiner novamente (sem gerar num novo conteiner)\n- **PowerShell**/***Bash***\n```PowerShell\ndocker start -a gng-rj99_p2\n```\n\n\n### Para apagar os conteiners da imagem e a imagem:\n\n#### 1. Parar todas os conteiners da imagem \"*problem_2:gabrielng-rj99*\"\n\n---\n\n- **PowerShell** `docker ps -aq --filter ancestor=problem_2:gabrielng-rj99 | ForEach-Object { docker stop $_ }`\n\n- ***Bash*** `docker ps -a | grep problem_2:gabrielng-rj99 | awk '{print $1}' | xargs docker stop`\n\n---\n\n#### 2. Remover todas os conteiners da imagem \"*problem_2:gabrielng-rj99*\"\n\n---\n\n- **PowerShell** `docker ps -aq --filter ancestor=problem_2:gabrielng-rj99 | ForEach-Object { docker rm $_ }`\n\n- ***Bash*** `docker ps -a | grep problem_2:gabrielng-rj99 | awk '{print $1}' | xargs docker rm`\n\n--- \n\n#### 3. Remover a imagem criada\n- **PowerShell**/***Bash***\n```bash\ndocker rmi problem_2:gabrielng-rj99\n```\n\n# Notas:\n\n1. Para timar facilmente os runtimes do dockerfile basta editar o Dockerfile \"run_commands.sh\" (nas linhas \"RUN\" e \"CMD\") para \"runtime.sh\" dependendo do método pra avaliar.\n\n2. Sinta-se a vontade para alterar os parâmetros do benchmark como \nWARMUP e RUNS no runtime.sh\n\n### Rodar mais exemplos/arquivos\n- basta colocar todos os arquivos na pasta \"examples\" abaixo **ANTES** de criar a **imagem** como na foto do **\"*Resultado Esperado*\"**\n> Path / to /submissions/gabrielng-rj99/Problema_2/Python/examples"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_2/Python/examples/exemplo_01.txt",
    "content": "40 47\n1 2\n1 24\n2 12\n3 18\n3 22\n4 11\n4 29\n4 32\n5 6\n5 27\n6 12\n6 22\n7 15\n7 17\n8 13\n8 15\n8 36\n9 17\n9 21\n10 18\n10 30\n10 32\n11 40\n12 31\n13 22\n13 31\n14 25\n14 32\n16 19\n16 23\n16 24\n17 20\n18 33\n19 38\n20 23\n21 38\n23 35\n25 39\n26 27\n28 33\n28 35\n29 34\n29 37\n30 34\n33 36\n36 40\n37 39\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_2/Python/examples/exemplo_02.txt",
    "content": "30 35\n1 3\n1 16\n2 9\n2 23\n3 8\n3 23\n4 18\n4 22\n4 30\n5 6\n5 11\n6 9\n6 19\n7 16\n7 18\n7 20\n8 26\n8 27\n9 18\n9 21\n10 13\n10 30\n12 15\n12 22\n13 17\n14 24\n14 28\n15 17\n19 27\n20 21\n21 29\n22 24\n24 26\n25 28\n25 29\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_2/Python/examples/exemplo_03.txt",
    "content": "30 218\n1 3\n1 8\n1 9\n1 11\n1 12\n1 13\n1 14\n1 16\n1 18\n1 20\n1 22\n1 24\n1 26\n1 27\n1 28\n2 8\n2 9\n2 11\n2 12\n2 14\n2 15\n2 19\n2 22\n2 26\n2 29\n3 7\n3 9\n3 10\n3 11\n3 12\n3 14\n3 20\n3 22\n3 23\n3 27\n3 29\n3 30\n4 9\n4 10\n4 11\n4 12\n4 14\n4 16\n4 18\n4 19\n4 21\n4 23\n4 25\n4 29\n4 30\n5 6\n5 9\n5 11\n5 13\n5 14\n5 15\n5 16\n5 17\n5 22\n5 23\n5 24\n5 28\n5 29\n6 8\n6 9\n6 13\n6 14\n6 17\n6 18\n6 19\n6 21\n6 26\n6 29\n7 9\n7 10\n7 11\n7 12\n7 13\n7 17\n7 18\n7 20\n7 22\n7 25\n8 9\n8 12\n8 16\n8 17\n8 21\n8 22\n8 24\n8 26\n8 28\n8 30\n9 11\n9 12\n9 14\n9 18\n9 21\n9 22\n9 23\n9 24\n9 27\n9 28\n9 30\n10 11\n10 12\n10 15\n10 18\n10 20\n10 21\n10 22\n10 27\n10 28\n10 30\n11 12\n11 14\n11 15\n11 16\n11 17\n11 18\n11 19\n11 21\n11 22\n11 23\n11 27\n11 28\n12 13\n12 15\n12 16\n12 20\n12 21\n12 22\n12 23\n12 25\n12 27\n12 29\n13 15\n13 17\n13 19\n13 20\n13 22\n13 23\n13 24\n13 27\n13 28\n13 29\n13 30\n14 15\n14 16\n14 21\n14 22\n14 24\n14 25\n14 27\n15 16\n15 17\n15 18\n15 19\n15 20\n15 23\n15 24\n15 28\n15 29\n16 17\n16 18\n16 19\n16 20\n16 23\n16 24\n16 25\n16 27\n16 28\n16 29\n17 21\n17 22\n17 23\n17 24\n17 28\n18 19\n18 24\n18 25\n18 30\n19 20\n19 22\n19 24\n19 25\n19 29\n19 30\n20 21\n20 22\n20 26\n20 29\n20 30\n21 22\n21 23\n21 24\n21 26\n21 28\n21 30\n22 24\n22 26\n22 27\n22 28\n23 24\n23 28\n24 25\n24 27\n24 28\n25 26\n25 27\n25 30\n26 28\n26 29\n26 30\n27 29\n27 30\n28 29\n29 30\n"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_2/Python/problema-2.py",
    "content": "import networkx as nx\nimport sys\n\nG = nx.Graph()\nedges_count = {}\nans = 0\n\ndef count_edges(N, edges):\n    global edges_count\n    edges_count = {node: 0 for node in range(1, N + 1)}\n    for edge in edges:\n        for node in edge:\n            edges_count[node] += 1\n\ndef add_ans():\n    global ans, edges_count\n    for node in edges_count:\n        if edges_count[node] == 1:\n            ans += 1\n\ndef open_edges_file(file_path):\n    with open(file_path, 'r') as file:\n        _N, W = map(int, file.readline().split())\n        \n        file_array = []\n\n        for line in file:\n            row = tuple(map(int, line.split()))\n            file_array.append(row)\n               \n        return _N, W, file_array\n\ndef roots_leaves_from(cycle: list):\n    global edges_count\n    roots = []\n    leaves = []\n\n    for node in cycle:\n        if not roots:\n            roots = [node]\n        elif edges_count[node] > edges_count[roots[0]]:\n            roots = [node]\n        elif edges_count[node] == edges_count[roots[0]]:\n            roots.append(node)\n        \n        if not leaves:\n            leaves = [node]\n        elif edges_count[node] < edges_count[leaves[0]]:\n            leaves = [node]\n        elif edges_count[node] == edges_count[leaves[0]]:\n            leaves.append(node)\n\n    return roots, leaves\n\ndef is_connected(nodes: list):\n    global G\n    for node in nodes:\n        connections = list(G.neighbors(node))\n        for node_2 in connections:\n            if node_2 in nodes:\n                return True\n    \n    return False\n\ndef leaves_connected_to_not_roots(leaves, roots, cycle):\n    global G\n    for leaf in leaves:\n        connections = list(G.neighbors(leaf))\n        for node in connections:\n            if node not in roots and node in cycle:\n                return True\n    \n    return False\n\ndef erase_edge_from(cycle):\n    global G\n    roots, leaves = roots_leaves_from(cycle)[0], roots_leaves_from(cycle)[1] \n    if len(leaves) >= 2:\n        if is_connected(leaves):\n            for i in range(-1, len(leaves) - 1):\n                if G.has_edge(leaves[i], leaves[i + 1]):\n                    G.remove_edge(leaves[i], leaves[i + 1])\n                    edges_count[leaves[i]] -= 1\n                    edges_count[leaves[i + 1]] -= 1\n                    break\n        \n        elif leaves_connected_to_not_roots(leaves, roots, cycle):\n            for i in range(-1, len(cycle) - 1):\n                c1 = cycle[i] in leaves\n                c2 = cycle[i + 1] in leaves\n                c3 = cycle[i] not in roots\n                c4 = cycle[i + 1] not in roots\n\n                check1 = all([c1, c4])\n                check2 = all([c2, c3])\n\n                if check1 or check2:\n                    G.remove_edge(cycle[i], cycle[i + 1])\n                    edges_count[cycle[i]] -= 1\n                    edges_count[cycle[i + 1]] -= 1\n                    break\n\n        else:\n            for i in range(-1, len(cycle) - 1):\n                check1 = cycle[i] in leaves\n                check2 = cycle[i + 1] in leaves\n\n                if check1 or check2:\n                    # print(\"checkpoint 1.3.1\")\n                    G.remove_edge(cycle[i], cycle[i + 1])\n                    edges_count[cycle[i]] -= 1\n                    edges_count[cycle[i + 1]] -= 1\n                    break\n\n    else:\n        if leaves_connected_to_not_roots(leaves, roots, cycle):\n            for i in range(-1, len(cycle) - 1):\n                c1 = cycle[i] in leaves\n                c2 = cycle[i + 1] in leaves\n                c3 = cycle[i] not in roots\n                c4 = cycle[i + 1] not in roots\n\n                check1 = c1 or c2\n                check2 = c3 or c4\n\n                if check1 and check2:\n                    G.remove_edge(cycle[i], cycle[i + 1])\n                    edges_count[cycle[i]] -= 1\n                    edges_count[cycle[i + 1]] -= 1\n                    break\n\n        else:\n            for i in range(-1, len(cycle) - 1):\n                check1 = cycle[i] in leaves\n                check2 = cycle[i + 1] in leaves\n\n                if check1 or check2:\n                    G.remove_edge(cycle[i], cycle[i + 1])\n                    edges_count[cycle[i]] -= 1\n                    edges_count[cycle[i + 1]] -= 1\n                    break\n\ndef find_cycle_starting_from(start_node):\n    global G\n    try:\n        cycle_edges = nx.find_cycle(G, source=start_node)\n        cycle_nodes = [u for u, _ in cycle_edges]\n        return cycle_nodes\n    except nx.NetworkXNoCycle:\n        return None\n\ndef break_all_cycles():\n    global G\n    start_node = max(edges_count, key=edges_count.get)\n    while nx.cycle_basis(G):\n        cycle = find_cycle_starting_from(start_node)\n        erase_edge_from(cycle)\n\ndef main(file_path):\n    global G, ans\n    N, _W, file_array = open_edges_file(file_path)\n    G.add_edges_from(file_array)\n    count_edges(N, file_array)\n    break_all_cycles()\n    add_ans()\n\n    return ans\n\nif __name__ == '__main__':\n    file_path = sys.argv[1]\n    print(f\"{main(file_path):>10}\")"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_2/Python/run_commands.sh",
    "content": "#!/bin/sh\n\nMFNL=0          # Max FileName Length Start\n\nfor file in examples/*\ndo\n  filename=$(basename $file)\n  len=$(echo -n \"$filename\" | wc -c)\n  if [ $len -gt $MFNL ]; then\n    MFNL=$len\n  fi\ndone\n\nclear\n\nprintf \"%-${MFNL}s  %s \\t \\n\" \"FileName\" \"Respostas\"\nfor file in examples/*\ndo\n  output=$(python problema-2.py $file)\n  filename=$(basename $file)\n  printf \"%-${MFNL}s $output\\n\" \"$filename\"\ndone"
  },
  {
    "path": "submissions/gabrielng-rj99/Problema_2/Python/runtime.sh",
    "content": "#!/bin/sh\n\nWARMUP=10\nRUNS=10\nSUM_MEANS=0\nFILE_COUNT=0\nMFNL=0          # Max FileName Length Start\n\nfor file in examples/*\ndo\n  filename=$(basename $file)\n  len=$(echo -n \"$filename\" | wc -c)\n  if [ $len -gt $MFNL ]; then\n    MFNL=$len\n  fi\ndone\n\n\nclear\n\necho -e \"\\n\\nRodará um (Hyperfine) Benchmark de $RUNS runs para cada arquivo\"\necho -e \"Depois pego as médias numa jq, e calculo ao final a soma das médias\"\necho -e \"Isso foi feito para facilitar a execução e visualização dos resultados\\n\\n\"\n\nprintf \"%-${MFNL}s  %s \\t %s \\n\" \"FileName\" \"Respostas\" \"Runtime\"\nfor file in examples/*\ndo\n  result=$(hyperfine --warmup $WARMUP --runs $RUNS \"python problema-2.py $file\" --export-json /tmp/hyperfine_results.json 2>/dev/null)\n  \n  output=$(python problema-2.py $file)\n  filename=$(basename $file)\n  mean=$(jq -r '.results | .[0].mean' /tmp/hyperfine_results.json)\n  \n  formatted_mean=$(printf \"%.9f\" $mean)\n  SUM_MEANS=$(echo \"$SUM_MEANS + $mean\" | bc)\n  FILE_COUNT=$((FILE_COUNT + 1))\n  \n  printf \"%-${MFNL}s $output \\t $formatted_mean s\\n\" \"$filename\"\ndone\n\nAVERAGE_MEAN=$(echo \"scale=9; $SUM_MEANS / $FILE_COUNT\" | bc)\n\nTOTAL_RUNTIME=$(printf \"%.9f\" $SUM_MEANS)\nAVERAGE_MEAN=$(printf \"%.9f\" $AVERAGE_MEAN)\n\necho -e \"\\nTotal Runtime:   \\t\\t $TOTAL_RUNTIME s\\n\"\necho -e \"\\nAvarage Runtime: \\t\\t $AVERAGE_MEAN s\\n\\n\""
  },
  {
    "path": "submissions/gbpagano/Cargo.toml",
    "content": "[package]\nname = \"gbpagano\"\nversion = \"0.1.0\"\nedition = \"2021\"\n\n# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html\n\n[dependencies]\n"
  },
  {
    "path": "submissions/gbpagano/README.md",
    "content": "# Usage\n\nrun with cargo\n\n```sh\ncargo run --release -- {filepath}\n```\n\nexample: \n\n```sh\ncargo run --release -- ../../resources/instances/problem_01/exemplo_01.txt\n```\n"
  },
  {
    "path": "submissions/gbpagano/exemplo.txt",
    "content": "25 45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n"
  },
  {
    "path": "submissions/gbpagano/src/main.rs",
    "content": "use std::env;\nuse std::fs::File;\nuse std::io::{self, BufRead};\n\nfn main() {\n    let args: Vec<_> = env::args().collect();\n    let file = File::open(&args[1]).unwrap();\n\n    let lines: Vec<_> = io::BufReader::new(file)\n        .lines()\n        .map(|line| line.unwrap())\n        .collect();\n\n    let capacity = lines[0]\n        .split_whitespace()\n        .nth(1)\n        .unwrap()\n        .parse::<usize>()\n        .unwrap();\n\n    let items: Vec<(usize, usize)> = lines[1..]\n        .iter()\n        .map(|line| {\n            let parts = line.split_whitespace().collect::<Vec<_>>();\n            (parts[0].parse().unwrap(), parts[1].parse().unwrap())\n        })\n        .collect();\n\n    let mut max_values = vec![0; capacity + 1];\n\n    for (weight, value) in items {\n        for w in (weight..=capacity).rev() {\n            max_values[w] = max_values[w].max(max_values[w - weight] + value);\n        }\n    }\n\n    println!(\"result: {}\", max_values[capacity]);\n}\n"
  },
  {
    "path": "submissions/gutogalego/Cargo.toml",
    "content": "[package]\nname = \"gutogalego\"\nversion = \"0.1.0\"\nedition = \"2021\"\n\n# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html"
  },
  {
    "path": "submissions/gutogalego/README.md",
    "content": "To run this, have rust installed, and run:\n\n```\ncargo run --release -- your_filename.txt\n```\n\nfor example \n\n```\ncargo run --release -- ../../resources/instances/problem_01/exemplo_03.txt\n```"
  },
  {
    "path": "submissions/gutogalego/src/main.rs",
    "content": "use std::env;\nuse std::fs::File;\nuse std::io::{self, BufRead};\nuse std::path::Path;\n\nfn knapsack(items: &[(usize, usize)], capacity: usize) -> usize {\n    let mut dp = vec![0; capacity + 1];\n\n    for &(weight, value) in items {\n        for w in (weight..=capacity).rev() {\n            dp[w] = std::cmp::max(dp[w], dp[w - weight] + value);\n        }\n    }\n\n    dp[capacity]\n}\n\nfn main() -> io::Result<()> {\n    let args: Vec<String> = env::args().collect();\n    if args.len() < 2 {\n        eprintln!(\"Usage: {} <filename>\", args[0]);\n        std::process::exit(1);\n    }\n    let filename = &args[1];\n\n    let path = Path::new(filename);\n    let file = File::open(&path)?;\n\n    let lines: Vec<String> = io::BufReader::new(file).lines().filter_map(|line| line.ok()).collect();\n    let capacity: usize = lines[0].split_whitespace().nth(1).unwrap().parse().unwrap();\n\n    let items: Vec<(usize, usize)> = lines[1..]\n        .iter()\n        .map(|line| {\n            let parts: Vec<&str> = line.split_whitespace().collect();\n            let weight: usize = parts[0].parse().unwrap();\n            let value: usize = parts[1].parse().unwrap();\n            (weight, value)\n        })\n        .collect();\n\n    let max_value = knapsack(&items, capacity);\n\n    println!(\"Solution: {}\", max_value);\n\n    Ok(())\n}\n"
  },
  {
    "path": "submissions/gutogalego__2/Cargo.toml",
    "content": "[package]\nname = \"gutogalego__2\"\nversion = \"0.1.0\"\nedition = \"2021\"\n\n# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html"
  },
  {
    "path": "submissions/gutogalego__2/README.md",
    "content": "To run this, have rust installed, and run:\n\n```\ncargo run --release -- your_filename.txt\n```\n\nfor example \n\n```\ncargo run --release -- ../../resources/instances/problem_01/exemplo_03.txt\n```"
  },
  {
    "path": "submissions/gutogalego__2/src/main.rs",
    "content": "use std::env;\nuse std::fs::File;\nuse std::io::{self, BufRead};\nuse std::path::Path;\n\nfn main() -> io::Result<()> {\n    let args: Vec<String> = env::args().collect();\n    if args.len() < 2 {\n        eprintln!(\"Usage: {} <filename>\", args[0]);\n        std::process::exit(1);\n    }\n    let filename = &args[1];\n\n    let path = Path::new(filename);\n    let file = File::open(&path)?;\n\n    let lines: Vec<String> = io::BufReader::new(file).lines().filter_map(|line| line.ok()).collect();\n    let capacity: usize = lines[0].split_whitespace().nth(1).unwrap().parse().unwrap();\n\n    let mut items: Vec<(usize, usize, f64)> = lines[1..]\n        .iter()\n        .map(|line| {\n            let parts: Vec<&str> = line.split_whitespace().collect();\n            let weight: usize = parts[0].parse().unwrap();\n            let value: usize = parts[1].parse().unwrap();\n            let ratio: f64 = value as f64 / weight as f64;\n            (weight, value, ratio)\n        })\n        .collect();\n\n    items.sort_by(|a, b| b.2.partial_cmp(&a.2).unwrap());\n\n    let mut max_value: f64 = 0.0;\n    let mut remaining_capacity = capacity;\n\n    for &(weight, value, _) in &items {\n        if weight <= remaining_capacity {\n            max_value += value as f64;\n            remaining_capacity -= weight;\n        } else {\n            max_value += value as f64 * (remaining_capacity as f64 / weight as f64);\n            break;\n        }\n    }\n\n    println!(\"Solution: {}\", max_value);\n\n    Ok(())\n}"
  },
  {
    "path": "submissions/gutogalego__3/Cargo.toml",
    "content": "[package]\nname = \"gutogalego__3\"\nversion = \"0.1.0\"\nedition = \"2021\"\n\n# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html"
  },
  {
    "path": "submissions/gutogalego__3/README.md",
    "content": "To run this, have rust installed, and run:\n\n```\ncargo run --release -- your_filename.txt\n```\n\nfor example \n\n```\ncargo run --release -- ../../resources/instances/problem_01/exemplo_03.txt\n```"
  },
  {
    "path": "submissions/gutogalego__3/src/main.rs",
    "content": "use std::env;\nuse std::fs::File;\nuse std::io::{self, BufRead};\nuse std::path::Path;\n\nfn main() -> io::Result<()> {\n    let args: Vec<String> = env::args().collect();\n    if args.len() < 2 {\n        eprintln!(\"Usage: {} <filename>\", args[0]);\n        std::process::exit(1);\n    }\n    let filename = &args[1];\n\n    let path = Path::new(filename);\n    let file = File::open(&path)?;\n\n    let lines: Vec<String> = io::BufReader::new(file).lines().filter_map(|line| line.ok()).collect();\n    let capacity: usize = lines[0].split_whitespace().nth(1).unwrap().parse().unwrap();\n\n    let items: Vec<(usize, usize)> = lines[1..]\n        .iter()\n        .map(|line| {\n            let parts: Vec<&str> = line.split_whitespace().collect();\n            let weight: usize = parts[0].parse().unwrap();\n            let value: usize = parts[1].parse().unwrap();\n            (weight, value)\n        })\n        .collect();\n\n    let mut max_value: f64 = 0.0;\n    let mut remaining_capacity = capacity;\n\n    for &(weight, value) in &items {\n        if weight <= remaining_capacity {\n            max_value += value as f64;\n            remaining_capacity -= weight;\n        } else {\n            max_value += value as f64 * (remaining_capacity as f64 / weight as f64);\n            break;\n        }\n    }\n\n    let adjusted_max_value = max_value * 1.33;\n\n    println!(\"Solution: {}\", adjusted_max_value);\n\n    Ok(())\n}\n"
  },
  {
    "path": "submissions/jaiaani/problema_01/.gitignore",
    "content": "/target\n/classes\n/checkouts\nprofiles.clj\npom.xml\npom.xml.asc\n*.jar\n*.class\n/.lein-*\n/.nrepl-port\n/.prepl-port\n.hgignore\n.hg/\n.DS*\n"
  },
  {
    "path": "submissions/jaiaani/problema_01/Dockerfile",
    "content": "FROM clojure:latest\n\n# Set the working directory to /app\nWORKDIR /app\n\n# Copy the current directory contents into the container at /app\nCOPY . /app\n\n# Install additional dependencies using lein\nRUN lein deps\n\n# Build the Clojure application\nRUN lein uberjar\n\nCMD [\"java\", \"-jar\", \"target/plantation-profit-0.1.0-SNAPSHOT-standalone.jar\"]"
  },
  {
    "path": "submissions/jaiaani/problema_01/LICENSE",
    "content": "Eclipse Public License - v 2.0\n\n    THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE\n    PUBLIC LICENSE (\"AGREEMENT\"). ANY USE, REPRODUCTION OR DISTRIBUTION\n    OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT.\n\n1. DEFINITIONS\n\n\"Contribution\" means:\n\n  a) in the case of the initial Contributor, the initial content\n     Distributed under this Agreement, and\n\n  b) in the case of each subsequent Contributor:\n     i) changes to the Program, and\n     ii) additions to the Program;\n  where such changes and/or additions to the Program originate from\n  and are Distributed by that particular Contributor. A Contribution\n  \"originates\" from a Contributor if it was added to the Program by\n  such Contributor itself or anyone acting on such Contributor's behalf.\n  Contributions do not include changes or additions to the Program that\n  are not Modified Works.\n\n\"Contributor\" means any person or entity that Distributes the Program.\n\n\"Licensed Patents\" mean patent claims licensable by a Contributor which\nare necessarily infringed by the use or sale of its Contribution alone\nor when combined with the Program.\n\n\"Program\" means the Contributions Distributed in accordance with this\nAgreement.\n\n\"Recipient\" means anyone who receives the Program under this Agreement\nor any Secondary License (as applicable), including Contributors.\n\n\"Derivative Works\" shall mean any work, whether in Source Code or other\nform, that is based on (or derived from) the Program and for which the\neditorial revisions, annotations, elaborations, or other modifications\nrepresent, as a whole, an original work of authorship.\n\n\"Modified Works\" shall mean any work in Source Code or other form that\nresults from an addition to, deletion from, or modification of the\ncontents of the Program, including, for purposes of clarity any new file\nin Source Code form that contains any contents of the Program. Modified\nWorks shall not include works that contain only declarations,\ninterfaces, types, classes, structures, or files of the Program solely\nin each case in order to link to, bind by name, or subclass the Program\nor Modified Works thereof.\n\n\"Distribute\" means the acts of a) distributing or b) making available\nin any manner that enables the transfer of a copy.\n\n\"Source Code\" means the form of a Program preferred for making\nmodifications, including but not limited to software source code,\ndocumentation source, and configuration files.\n\n\"Secondary License\" means either the GNU General Public License,\nVersion 2.0, or any later versions of that license, including any\nexceptions or additional permissions as identified by the initial\nContributor.\n\n2. GRANT OF RIGHTS\n\n  a) Subject to the terms of this Agreement, each Contributor hereby\n  grants Recipient a non-exclusive, worldwide, royalty-free copyright\n  license to reproduce, prepare Derivative Works of, publicly display,\n  publicly perform, Distribute and sublicense the Contribution of such\n  Contributor, if any, and such Derivative Works.\n\n  b) Subject to the terms of this Agreement, each Contributor hereby\n  grants Recipient a non-exclusive, worldwide, royalty-free patent\n  license under Licensed Patents to make, use, sell, offer to sell,\n  import and otherwise transfer the Contribution of such Contributor,\n  if any, in Source Code or other form. This patent license shall\n  apply to the combination of the Contribution and the Program if, at\n  the time the Contribution is added by the Contributor, such addition\n  of the Contribution causes such combination to be covered by the\n  Licensed Patents. The patent license shall not apply to any other\n  combinations which include the Contribution. No hardware per se is\n  licensed hereunder.\n\n  c) Recipient understands that although each Contributor grants the\n  licenses to its Contributions set forth herein, no assurances are\n  provided by any Contributor that the Program does not infringe the\n  patent or other intellectual property rights of any other entity.\n  Each Contributor disclaims any liability to Recipient for claims\n  brought by any other entity based on infringement of intellectual\n  property rights or otherwise. As a condition to exercising the\n  rights and licenses granted hereunder, each Recipient hereby\n  assumes sole responsibility to secure any other intellectual\n  property rights needed, if any. For example, if a third party\n  patent license is required to allow Recipient to Distribute the\n  Program, it is Recipient's responsibility to acquire that license\n  before distributing the Program.\n\n  d) Each Contributor represents that to its knowledge it has\n  sufficient copyright rights in its Contribution, if any, to grant\n  the copyright license set forth in this Agreement.\n\n  e) Notwithstanding the terms of any Secondary License, no\n  Contributor makes additional grants to any Recipient (other than\n  those set forth in this Agreement) as a result of such Recipient's\n  receipt of the Program under the terms of a Secondary License\n  (if permitted under the terms of Section 3).\n\n3. REQUIREMENTS\n\n3.1 If a Contributor Distributes the Program in any form, then:\n\n  a) the Program must also be made available as Source Code, in\n  accordance with section 3.2, and the Contributor must accompany\n  the Program with a statement that the Source Code for the Program\n  is available under this Agreement, and informs Recipients how to\n  obtain it in a reasonable manner on or through a medium customarily\n  used for software exchange; and\n\n  b) the Contributor may Distribute the Program under a license\n  different than this Agreement, provided that such license:\n     i) effectively disclaims on behalf of all other Contributors all\n     warranties and conditions, express and implied, including\n     warranties or conditions of title and non-infringement, and\n     implied warranties or conditions of merchantability and fitness\n     for a particular purpose;\n\n     ii) effectively excludes on behalf of all other Contributors all\n     liability for damages, including direct, indirect, special,\n     incidental and consequential damages, such as lost profits;\n\n     iii) does not attempt to limit or alter the recipients' rights\n     in the Source Code under section 3.2; and\n\n     iv) requires any subsequent distribution of the Program by any\n     party to be under a license that satisfies the requirements\n     of this section 3.\n\n3.2 When the Program is Distributed as Source Code:\n\n  a) it must be made available under this Agreement, or if the\n  Program (i) is combined with other material in a separate file or\n  files made available under a Secondary License, and (ii) the initial\n  Contributor attached to the Source Code the notice described in\n  Exhibit A of this Agreement, then the Program may be made available\n  under the terms of such Secondary Licenses, and\n\n  b) a copy of this Agreement must be included with each copy of\n  the Program.\n\n3.3 Contributors may not remove or alter any copyright, patent,\ntrademark, attribution notices, disclaimers of warranty, or limitations\nof liability (\"notices\") contained within the Program from any copy of\nthe Program which they Distribute, provided that Contributors may add\ntheir own appropriate notices.\n\n4. COMMERCIAL DISTRIBUTION\n\nCommercial distributors of software may accept certain responsibilities\nwith respect to end users, business partners and the like. While this\nlicense is intended to facilitate the commercial use of the Program,\nthe Contributor who includes the Program in a commercial product\noffering should do so in a manner which does not create potential\nliability for other Contributors. Therefore, if a Contributor includes\nthe Program in a commercial product offering, such Contributor\n(\"Commercial Contributor\") hereby agrees to defend and indemnify every\nother Contributor (\"Indemnified Contributor\") against any losses,\ndamages and costs (collectively \"Losses\") arising from claims, lawsuits\nand other legal actions brought by a third party against the Indemnified\nContributor to the extent caused by the acts or omissions of such\nCommercial Contributor in connection with its distribution of the Program\nin a commercial product offering. The obligations in this section do not\napply to any claims or Losses relating to any actual or alleged\nintellectual property infringement. In order to qualify, an Indemnified\nContributor must: a) promptly notify the Commercial Contributor in\nwriting of such claim, and b) allow the Commercial Contributor to control,\nand cooperate with the Commercial Contributor in, the defense and any\nrelated settlement negotiations. The Indemnified Contributor may\nparticipate in any such claim at its own expense.\n\nFor example, a Contributor might include the Program in a commercial\nproduct offering, Product X. That Contributor is then a Commercial\nContributor. If that Commercial Contributor then makes performance\nclaims, or offers warranties related to Product X, those performance\nclaims and warranties are such Commercial Contributor's responsibility\nalone. Under this section, the Commercial Contributor would have to\ndefend claims against the other Contributors related to those performance\nclaims and warranties, and if a court requires any other Contributor to\npay any damages as a result, the Commercial Contributor must pay\nthose damages.\n\n5. NO WARRANTY\n\nEXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, AND TO THE EXTENT\nPERMITTED BY APPLICABLE LAW, THE PROGRAM IS PROVIDED ON AN \"AS IS\"\nBASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR\nIMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF\nTITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR\nPURPOSE. Each Recipient is solely responsible for determining the\nappropriateness of using and distributing the Program and assumes all\nrisks associated with its exercise of rights under this Agreement,\nincluding but not limited to the risks and costs of program errors,\ncompliance with applicable laws, damage to or loss of data, programs\nor equipment, and unavailability or interruption of operations.\n\n6. DISCLAIMER OF LIABILITY\n\nEXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, AND TO THE EXTENT\nPERMITTED BY APPLICABLE LAW, NEITHER RECIPIENT NOR ANY CONTRIBUTORS\nSHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,\nEXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST\nPROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\nCONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\nARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE\nEXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE\nPOSSIBILITY OF SUCH DAMAGES.\n\n7. GENERAL\n\nIf any provision of this Agreement is invalid or unenforceable under\napplicable law, it shall not affect the validity or enforceability of\nthe remainder of the terms of this Agreement, and without further\naction by the parties hereto, such provision shall be reformed to the\nminimum extent necessary to make such provision valid and enforceable.\n\nIf Recipient institutes patent litigation against any entity\n(including a cross-claim or counterclaim in a lawsuit) alleging that the\nProgram itself (excluding combinations of the Program with other software\nor hardware) infringes such Recipient's patent(s), then such Recipient's\nrights granted under Section 2(b) shall terminate as of the date such\nlitigation is filed.\n\nAll Recipient's rights under this Agreement shall terminate if it\nfails to comply with any of the material terms or conditions of this\nAgreement and does not cure such failure in a reasonable period of\ntime after becoming aware of such noncompliance. If all Recipient's\nrights under this Agreement terminate, Recipient agrees to cease use\nand distribution of the Program as soon as reasonably practicable.\nHowever, Recipient's obligations under this Agreement and any licenses\ngranted by Recipient relating to the Program shall continue and survive.\n\nEveryone is permitted to copy and distribute copies of this Agreement,\nbut in order to avoid inconsistency the Agreement is copyrighted and\nmay only be modified in the following manner. The Agreement Steward\nreserves the right to publish new versions (including revisions) of\nthis Agreement from time to time. No one other than the Agreement\nSteward has the right to modify this Agreement. The Eclipse Foundation\nis the initial Agreement Steward. The Eclipse Foundation may assign the\nresponsibility to serve as the Agreement Steward to a suitable separate\nentity. Each new version of the Agreement will be given a distinguishing\nversion number. The Program (including Contributions) may always be\nDistributed subject to the version of the Agreement under which it was\nreceived. In addition, after a new version of the Agreement is published,\nContributor may elect to Distribute the Program (including its\nContributions) under the new version.\n\nExcept as expressly stated in Sections 2(a) and 2(b) above, Recipient\nreceives no rights or licenses to the intellectual property of any\nContributor under this Agreement, whether expressly, by implication,\nestoppel or otherwise. All rights in the Program not expressly granted\nunder this Agreement are reserved. Nothing in this Agreement is intended\nto be enforceable by any entity that is not a Contributor or Recipient.\nNo third-party beneficiary rights are created under this Agreement.\n\nExhibit A - Form of Secondary Licenses Notice\n\n\"This Source Code may also be made available under the following\nSecondary Licenses when the conditions for such availability set forth\nin the Eclipse Public License, v. 2.0 are satisfied: GNU General Public\nLicense as published by the Free Software Foundation, either version 2\nof the License, or (at your option) any later version, with the GNU\nClasspath Exception which is available at\nhttps://www.gnu.org/software/classpath/license.html.\"\n\n  Simply including a copy of this Agreement, including this Exhibit A\n  is not sufficient to license the Source Code under Secondary Licenses.\n\n  If it is not possible or desirable to put the notice in a particular\n  file, then You may include the notice in a location (such as a LICENSE\n  file in a relevant directory) where a recipient would be likely to\n  look for such a notice.\n\n  You may add additional accurate notices of copyright ownership.\n"
  },
  {
    "path": "submissions/jaiaani/problema_01/README.md",
    "content": "# plantation-profit\n\nA Clojure library designed to ... well, that part is up to you.\n\n## Usage\n🇧🇷\nPara executar o programa siga os seguintes passos:\n\nUsando o docker...\n * Nesse mesmo diretório, rode o comando: `docker build -t problema1 .`\n * Depois rode o comando `docker run --rm -it problema1`\n   * Como input há 3 opções: \n      - example1\n      - example2\n      - example3 \n \n   são referentes aos exemplos dados, é somente uma concatenação para se referir\n      aos arquivos localizados na pasta ./resources/input,\n     ```clojure \n     (defn input\n        [example]\n        (with-open [rdr (reader (str \"./resources/input/\" example \".txt\"))]\n        (doall (mapv vector (line-seq rdr)))))```\n   \n  se for necessário testar outras entradas, é só adicionar o arquivo nessa pasta.\n\nEnglish -\n\nTo run the program, follow these steps:\n\nUsing docker...\n* In that same directory, run the command: `docker build problema1 .`\n* Then run the command `docker run --rm -it problema1`\n    * As input there are 3 options:\n        - example1\n        - example2\n        - example3\n\n  refer to the examples given, it is just a concatenation to refer\n  to files located in the ./resources/input folder,\n    ```clojure \n    (defn input\n       [example]\n       (with-open [rdr (reader (str \"./resources/input/\" example \".txt\"))]\n       (doall (mapv vector (line-seq rdr)))))```\n\nIf you need to test other entries, just add the file to this folder.\n\n## License\n\nCopyright © 2024 FIXME\n\nThis program and the accompanying materials are made available under the\nterms of the Eclipse Public License 2.0 which is available at\nhttp://www.eclipse.org/legal/epl-2.0.\n\nThis Source Code may also be made available under the following Secondary\nLicenses when the conditions for such availability set forth in the Eclipse\nPublic License, v. 2.0 are satisfied: GNU General Public License as published by\nthe Free Software Foundation, either version 2 of the License, or (at your\noption) any later version, with the GNU Classpath Exception which is available\nat https://www.gnu.org/software/classpath/license.html.\n"
  },
  {
    "path": "submissions/jaiaani/problema_01/project.clj",
    "content": "(defproject plantation-profit \"0.1.0-SNAPSHOT\"\n  :description \"FIXME: write description\"\n  :url \"http://example.com/FIXME\"\n  :license {:name \"EPL-2.0 OR GPL-2.0-or-later WITH Classpath-exception-2.0\"\n            :url \"https://www.eclipse.org/legal/epl-2.0/\"}\n  :dependencies [[org.clojure/clojure \"1.11.1\"]\n                 [prismatic/schema \"1.4.1\"]]\n  :repl-options {:init-ns plantation-profit.core}\n  :main plantation-profit.core)\n"
  },
  {
    "path": "submissions/jaiaani/problema_01/resources/input/example1.txt",
    "content": "22 36\n3\t86\n1\t80\n3\t71\n2\t39\n2\t53\n3\t47\n2\t46\n1\t32\n1\t69\n2\t89\n4\t58\n3\t86\n3\t54\n3\t53\n1\t64\n4\t82\n1\t46\n2\t48\n4\t53\n1\t68\n3\t94\n1\t87"
  },
  {
    "path": "submissions/jaiaani/problema_01/resources/input/example2.txt",
    "content": "9 10\n3\t44\n1\t78\n2\t64\n1\t49\n4\t69\n1\t87\n3\t78\n2\t45\n3\t84\n"
  },
  {
    "path": "submissions/jaiaani/problema_01/resources/input/example3.txt",
    "content": "25 45\n1\t38\n1\t99\n3\t78\n3\t60\n2\t69\n1\t32\n2\t100\n4\t59\n1\t67\n3\t80\n4\t44\n2\t96\n2\t48\n3\t46\n1\t74\n3\t65\n3\t32\n1\t30\n4\t87\n4\t90\n1\t40\n2\t71\n1\t86\n1\t98\n1\t99\n"
  },
  {
    "path": "submissions/jaiaani/problema_01/resources/input/results.txt",
    "content": "inputExample1.txt\t1194\ninputExample2.txt\t407\ninputExample3.txt\t1566\n"
  },
  {
    "path": "submissions/jaiaani/problema_01/src/plantation_profit/core.clj",
    "content": "(ns plantation-profit.core\n  (:require [schema.core :as s])\n  (:use clojure.string)\n  (:use clojure.java.io)\n  (:gen-class))\n\n(def InfosSemente\n  {:v s/Int\n   :w s/Int})\n\n(defn input\n  [example]\n  (with-open [rdr (reader (str \"./resources/input/\" example \".txt\"))]\n    (doall (mapv vector (line-seq rdr)))))\n\n(s/defn linha-semente->vetor-semente :- [s/Int s/Int]\n  [linha-input]\n  (mapv #(Integer/parseInt %) (clojure.string/split (first linha-input) #\"\\t\")))\n\n(defn elementos-do-input\n  [input]\n  {:primeira-linha (map #(Integer/parseInt %) (clojure.string/split (first (first input)) #\" \"))\n   :vetor-info-sementes (map #(linha-semente->vetor-semente %) (remove #{(first input)} input))})\n\n(s/defn wire->model-semente :- InfosSemente\n  [vetor-semente :- [s/Int s/Int]]\n  (let [espaco-necessario (first vetor-semente)\n        valor (second vetor-semente)]\n    {:v valor\n     :w espaco-necessario}))\n\n(s/defn lista-info-sementes :- [InfosSemente]\n  [vetor-semente :- [s/Int s/Int]]\n  (mapv #(wire->model-semente %) vetor-semente))\n\n(s/defn maximo-lucro-possivel\n  [quantidade-sementes :- s/Int\n   lista-de-sementes :- [InfosSemente]\n   espacos-disponiveis :- s/Int]\n  (if (or (zero? quantidade-sementes) (zero? espacos-disponiveis))\n    0\n    (let [semente (nth lista-de-sementes (dec quantidade-sementes))\n          espacos-restantes (- espacos-disponiveis (:w semente))]\n      (if (> (:w semente) espacos-disponiveis)\n        (maximo-lucro-possivel (dec quantidade-sementes) lista-de-sementes espacos-disponiveis)\n        (max (+ (:v semente) (maximo-lucro-possivel (dec quantidade-sementes) lista-de-sementes espacos-restantes))\n             (maximo-lucro-possivel (dec quantidade-sementes) lista-de-sementes espacos-disponiveis))))))\n\n(defn output\n  [arquivoExemplo]\n  (let [input (input (str arquivoExemplo))\n        elementos-do-input (elementos-do-input input)\n        lista-de-sementes (lista-info-sementes (:vetor-info-sementes elementos-do-input))\n        quantidade-de-sementes (first (:primeira-linha elementos-do-input))\n        espacos-disponiveis (second (:primeira-linha elementos-do-input))]\n    (println (str \"O maximo lucro possivel é de R$\"\n                  (maximo-lucro-possivel quantidade-de-sementes lista-de-sementes espacos-disponiveis)\n                  \",00\"))))\n\n(defn- exit [status msg]\n  (println msg)\n  (System/exit status))\n\n(defn -main\n  [& args]\n  (println \"As opcoes sao example1, example2, example3, referentes aos exemplos do projeto\")\n  (println \"Insira aqui o exemplo que voce deseja testar:\")\n  (-> (read-line)\n      output)\n  (exit 1 \"End\"))\n"
  },
  {
    "path": "submissions/jaiaani/problema_01/src/plantation_profit/english_core.clj",
    "content": "(ns plantation-profit.english-core\n  (:require [schema.core :as s])\n  (:use clojure.string)\n  (:use clojure.java.io)\n  (:gen-class))\n\n;The same code, but in an english version :)\n\n(def SeedInfo\n  {:v s/Int\n   :w s/Int})\n\n(defn input\n  [txt-path]\n  (with-open [rdr (reader (str txt-path))]\n    (doall (mapv vector (line-seq rdr)))))\n\n(s/defn seed-line->seed-vector :- [s/Int s/Int]\n  [input-line]\n  (mapv #(Integer/parseInt %) (clojure.string/split (first input-line) #\"\\t\")))\n\n(defn input-elements\n  [input]\n  {:first-line (map #(Integer/parseInt %) (clojure.string/split (first (first input)) #\" \"))\n   :seeds-informations (map #(seed-line->seed-vector %) (remove #{(first input)} input))})\n\n(s/defn wire->model-seed :- SeedInfo\n  [seed-vector :- [s/Int s/Int]]\n  (let [space-required (first seed-vector)\n        value (second seed-vector)]\n    {:v value\n     :w space-required}))\n\n(s/defn list-of-seeds :- [SeedInfo]\n  [seed-vector :- [s/Int s/Int]]\n  (mapv #(wire->model-seed %) seed-vector))\n\n(s/defn maximum-possible-profit :- s/Int\n  [seeds-qty :- s/Int\n   list-of-seeds :- [SeedInfo]\n   spaces-available :- s/Int]\n  (if (or (zero? seeds-qty) (zero? spaces-available))\n    0\n    (let [seed (nth list-of-seeds (dec seeds-qty))\n          remaining-spaces (- spaces-available (:w seed))]\n      (if (> (:w seed) spaces-available)\n        (maximum-possible-profit (dec seeds-qty) list-of-seeds spaces-available)\n        (max (+ (:v seed) (maximum-possible-profit (dec seeds-qty) list-of-seeds remaining-spaces))\n             (maximum-possible-profit (dec seeds-qty) list-of-seeds spaces-available))))))\n\n(defn output [filePath]\n  (let [input (input filePath)\n        input-elements (input-elements input)\n        list-of-seeds (list-of-seeds (:seeds-informations input-elements))\n        seeds-qty (first (:first-line input-elements))\n        spaces-available (second (:first-line input-elements))]\n    (println (str \"The maximum possible profit is R$\"\n                  (maximum-possible-profit seeds-qty list-of-seeds spaces-available) \",00\"))))\n\n(defn- exit [status msg]\n  (println msg)\n  (System/exit status))\n\n(defn -main\n  [& args]\n  (println \"The options are example1, example2, example3, referring to the project examples\")\n  (println \"Enter the example you want to test here:\")\n  (-> (read-line)\n      output)\n  (exit 1 \"End\"))\n"
  },
  {
    "path": "submissions/jaiaani/problema_01/test/plantation_profit/core_test.clj",
    "content": "(ns plantation-profit.core-test\n  (:require [clojure.test :refer :all]\n            [plantation-profit.core :as core]))\n\n(def lista-de-sementes\n  [{:v 86 :w 3}\n   {:v 80 :w 1}\n   {:v 71 :w 3}\n   {:v 39 :w 2}\n   {:v 53 :w 2}\n   {:v 47 :w 3}\n   {:v 46 :w 2}\n   {:v 32 :w 1}\n   {:v 69 :w 1}\n   {:v 89 :w 2}\n   {:v 58 :w 4}\n   {:v 86 :w 3}\n   {:v 54 :w 3}\n   {:v 53 :w 3}\n   {:v 64 :w 1}\n   {:v 82 :w 4}\n   {:v 46 :w 1}\n   {:v 48 :w 2}\n   {:v 53 :w 4}\n   {:v 68 :w 1}\n   {:v 94 :w 3}\n   {:v 87 :w 1}])\n\n(deftest maximo-lucro-possivel-test\n  (testing\n    \"Dada a quantidade de sementes, as informacoes da semente e os espacos disponiveis\n    deve retornar o maior lucro possivel\"\n    (is (= (core/maximo-lucro-possivel 22 lista-de-sementes 36)\n           1194))))\n"
  },
  {
    "path": "submissions/jojodev/README.md",
    "content": "## Como Executar\n\n**Pré-requisitos:**\n   - Tenha Python instalado.\n\n**Execução:**\n   - Abra um terminal no diretório do script.\n   - Execute o script com o comando:\n     ```\n     python problema-1.py input.txt\n     ```\n   - Exemplo:\n     ```\n     python problema-1.py ../../resources/instances/problem_01/exemplo_02.txt\n     ```\n    \n"
  },
  {
    "path": "submissions/jojodev/problema-1.py",
    "content": "import sys\n\ndef ler_entrada(nome_arquivo):\n    matriz = []\n\n    with open(nome_arquivo, 'r') as arquivo:\n        primeira_linha = arquivo.readline().split()\n        n, W = int(primeira_linha[0]), int(primeira_linha[1])\n\n        for _ in range(n):\n            linha = arquivo.readline().split()\n            semente = [int(linha[0]), int(linha[1])]\n            matriz.append(semente)\n\n        pesos = [item[0] for item in matriz]\n        valores = [item[1] for item in matriz]\n\n    return n, W, pesos, valores\n\n\ndef knapsack_iterativo(capacidade, pesos, valores, n):\n\n  tabela = [[0] * (capacidade + 1) for _ in range(n + 1)]\n\n  for i in range(1, n + 1):\n    for w in range(capacidade + 1):\n      if pesos[i - 1] <= w:\n        tabela[i][w] = max(valores[i - 1] + tabela[i - 1][w - pesos[i - 1]], tabela[i - 1][w])\n      else:\n        tabela[i][w] = tabela[i - 1][w]\n\n  return tabela[n][capacidade]\n\n\nif __name__ == \"__main__\":\n    nome_arquivo = sys.argv[1]\n    n, capacidade, pesos, valores = ler_entrada(nome_arquivo)\n    resultado = knapsack_iterativo(capacidade, pesos, valores, n)\n    print(resultado)\n    "
  },
  {
    "path": "submissions/juanplopes/.gitignore",
    "content": "*.in\n*.out\n"
  },
  {
    "path": "submissions/juanplopes/README.md",
    "content": "# Juan Lopes\n\nPara compilar e executar qualquer problema:\n\n```\ng++ -O2 problema-1.cpp && ./a.out < ../../resources/instances/problem_01/exemplo_01.txt\n```"
  },
  {
    "path": "submissions/juanplopes/problema-1.cpp",
    "content": "#include <iostream>\n#include <cstring>\n#include <cstdio>\n#include <algorithm>\nusing namespace std;\n\nint T[3030];\n\nint main() {\n    int N, W;\n    scanf(\"%d %d\", &N, &W);\n    T[0] = 1;\n    for(int i=0; i<N; i++) {\n        int wi, vi; \n        scanf(\"%d %d\", &wi, &vi);\n        for(int j=W - wi; j>=0; j--) {\n            if (T[j] <= 0) continue;\n            if (T[j] + vi > T[j + wi])\n                T[j + wi] = T[j] + vi;\n        }\n    }\n    printf(\"%d\\n\", *max_element(T, T+W+1)-1);\n}"
  },
  {
    "path": "submissions/marcosvile/Dockerfile",
    "content": "FROM bash:latest\n\nRUN apk add --no-cache bash\n\nCOPY problema-1.sh /app/problema-1.sh\n\nRUN chmod +x /app/problema-1.sh\n\nWORKDIR /app\n\nCMD [\"./problema-1.sh\"]"
  },
  {
    "path": "submissions/marcosvile/Readme.md",
    "content": "## Execução do Projeto\n\nEste projeto utiliza Docker para criar um ambiente isolado para a execução de scripts Bash. A seguir, são fornecidas instruções para construir a imagem Docker, executar o contêiner e passar um arquivo externo como entrada.\n\n1. Construa a imagem Docker e execute o contêiner:\n\n```\n$ docker build submissions/marcosvile/. -t problem_01 && time sudo docker run --rm --cpus=2 --memory=2g -v $(pwd)/[diretório do arquivo de entrada]:/app/resources problem_01 ./problema-1.sh resources/[nome do arquivo de entrada].txt\n```\n\nEste comando constrói a imagem a ser utilizada no contêiner contento o script bash, e executa um contêiner a partir dessa imagem parametrizado conforme os requisitos do problema com dois núcleos de CPU, 2 GB de RAM e mapeia o diretório local passado pela flag -v, para dentro do contêiner. Certifique-se de substituir o nome do diretório onde contém o arquivo de entrada e o nome utilizado pelo arquivo de entrada externo.\n\nCertifique-se de ajustar os caminhos e nomes de arquivo conforme necessário com base na sua estrutura de diretórios e requisitos específicos.\n"
  },
  {
    "path": "submissions/marcosvile/problema-1.sh",
    "content": "#!/bin/bash\n\nset -exo pipefail\n\nmain() {\n\n    chmod +r \"$1\"\n    \n    local arquivo=$1\n\n    if [ \"$#\" -ne 1 ]; then\n        echo \"Arquivo de entrada não especificado.\"\n        exit 1\n    fi\n\n    if [ ! -e \"$arquivo\" ]; then\n        echo \"O arquivo '$arquivo' não existe.\"\n        exit 1\n    fi\n\n    calcular_lucro_maximo \"$arquivo\"\n}\n\ncalcular_lucro_maximo() {\n    local arquivo=$1\n    declare -a linhas_array=()\n\n    while IFS= read -r linha; do\n        linhas_array+=(\"$linha\")\n    done < \"$arquivo\"\n\n    read -r quantidade_sementes quantidade_espacos <<< \"${linhas_array[0]}\"\n\n    if [ \"$quantidade_sementes\" -lt 1 ] || [ \"$quantidade_sementes\" -gt 1000 ] || \\\n       [ \"$quantidade_espacos\" -lt 1 ] || [ \"$quantidade_espacos\" -gt 2666 ]; then\n        echo \"Quantidades de sementes ou espaços fora dos limites permitidos.\"\n        exit 1\n    fi\n\n    declare -a valores=()\n    declare -a espacos_necessarios=()\n\n    for ((i = 1; i <= quantidade_sementes; i++)); do\n        read -r espaco_necessario valor <<< \"${linhas_array[i]}\"\n        if [ \"$espaco_necessario\" -lt 1 ] || [ \"$espaco_necessario\" -gt 7 ] || \\\n           [ \"$valor\" -lt 30 ] || [ \"$valor\" -gt 200 ]; then\n            echo \"Valores de espaço necessário ou valor fora dos limites permitidos.\"\n            exit 1\n        fi\n        espacos_necessarios+=(\"$espaco_necessario\")\n        valores+=(\"$valor\")\n    done\n\n    declare -a lucro_maximo=()\n    for ((i = 0; i <= quantidade_espacos; i++)); do\n        lucro_maximo+=(\"0\")\n    done\n\n    for ((i = 1; i <= quantidade_sementes; i++)); do\n        for ((j = quantidade_espacos; j >= espacos_necessarios[i-1]; j--)); do\n            lucro_potencial=$((valores[i-1] + lucro_maximo[j - espacos_necessarios[i-1]]))\n            if [ \"$lucro_potencial\" -gt \"${lucro_maximo[j]}\" ]; then\n                lucro_maximo[j]=$lucro_potencial\n            fi\n        done\n    done\n\n    echo \"Lucro máximo usando todas as sementes e espaço possível: ${lucro_maximo[quantidade_espacos]}\"\n}\n\nmain \"$@\""
  },
  {
    "path": "submissions/olegon/.gitignore",
    "content": "/a.out\n"
  },
  {
    "path": "submissions/olegon/README.md",
    "content": "# Como rodar?\n\nEu deixei um script chamado `compile-and-run.sh`, então basta executá-lo:\n\n```bash\n./compile-and-run.sh\n```\n\nA saída esperada é:\n\n```plain\nPreparing...\nExpected results are:\ninstances/exemplo_01.txt        1194\ninstances/exemplo_02.txt        407\ninstances/exemplo_03.txt        1566\nRunning for input file: ../../resources/instances/problem_01/exemplo_01.txt\n1194\nRunning for input file: ../../resources/instances/problem_01/exemplo_02.txt\n407\nRunning for input file: ../../resources/instances/problem_01/exemplo_03.txt\n1566\n```\n\n# Qual linguagem foi utilizada?\n\nEu utilizei C++ por preferência pessoal e por ser uma linguagem muito rápida.\n\n# Como resolvi?\n\nPara cada semente, eu testo o valor obtido caso eu plante a semente e caso eu descarte a semente. É necessário testar o caso de descartar a semente, por mais que ela parece ótima, porque combinações de outras sementes podem gerar um valor melhor. A desvantagem de fazer isso é que eu posso calcular as mesmas combinações várias vezes:\n\n- Caso 1: descartar - descartar - descartar - descartar - descartar\n- Caso 2: descartar - descartar - descartar - descartar - **plantar**\n- Caso 3: descartar - descartar - descartar - **plantar** - descartar\n- Caso 4: descartar - descartar - descartar - **plantar** - **plantar**\n\nComo exemplo, os casos 3 e 4 repetem os casos 1 e 2, e isto vai acontecer várias vezes. Para resolver esse problema, eu usei um *cache* para guardar as computações já feitas e reutilizá-las. Problemas com característica de subproblemas que se repetem e que podem ser usados para resolver problemas maiores podem ser resolvidos com *programação dinâmica*, que foi o que utilizei.\n"
  },
  {
    "path": "submissions/olegon/compile-and-run.sh",
    "content": "#!/bin/bash\n\nset -e\n\necho \"Preparing...\"\ng++ main.cpp -W -Wall -std=c++14 -O3\n\necho \"Expected results are:\"\ncat \"../../resources/instances/problem_01/resultados.txt\"\n\nfor f in ../../resources/instances/problem_01/exemplo_*.txt; do\n    echo \"Running for input file: $f\";\n    cat \"$f\" | ./a.out;\ndone;\n"
  },
  {
    "path": "submissions/olegon/main.cpp",
    "content": "/*\nRinha de algoritmos - Problema 01\nhttps://github.com/olegon/rinha-de-algoritmos/blob/main/how_to_participate.md#problema-01\n*/\n\n#include <bits/stdc++.h>\n\nusing namespace std;\n\nint optimize(int i, int n, vector<int> &w, vector<int> &v, int W, vector<vector<int>> &dp);\n\nint main(void) {\n    ios::sync_with_stdio(false);\n\n    int n, W;\n    \n    cin >> n >> W;\n\n    vector<int> w(n), v(n);\n    \n    for (int i = 0; i < n; i++) {\n        cin >> w[i];\n        cin >> v[i];\n    }\n\n    vector<vector<int>> dp(n, vector<int>(W + 1, -1));\n\n    cout << optimize(0, n, w, v, W, dp) << endl;\n\n    return EXIT_SUCCESS;\n}\n\nint optimize(int i, int n, vector<int> &w, vector<int> &v, int W, vector<vector<int>> &dp) {\n    if (i >= n) return 0;\n\n    if (dp[i][W] != -1) return dp[i][W];\n\n    if (w[i] > W) return optimize(i + 1, n, w, v, W, dp);\n\n    int value_taking_current_seed = v[i] + optimize(i + 1, n, w, v, W - w[i], dp);\n    int value_skipping_current_seed = optimize(i + 1, n, w, v, W, dp);\n\n    dp[i][W] = max(value_taking_current_seed, value_skipping_current_seed);\n\n    return dp[i][W];\n}\n"
  },
  {
    "path": "submissions/ryrden/README.md",
    "content": "\n# Pré-requisitos\n\n- [Golang](https://golang.org/dl/)\n\n# Execução\n\n**Linux:**\n\n```bash\ngo run ryrden.go < ../../resourcers/instances/problem_01/exemplo_01.txt\n```\n\n**Windows:**\n\n```bash\nGet-Content ../../resourcers/instances/problem_01/exemplo_01.txt | go run ryrden.go\n```\n"
  },
  {
    "path": "submissions/ryrden/go.mod",
    "content": "module github.com/ryrden/rinha-de-algoritmos\n\ngo 1.18\n"
  },
  {
    "path": "submissions/ryrden/ryrden.go",
    "content": "package main\n\nimport (\n\t\"bufio\"\n\t\"fmt\"\n\t\"os\"\n)\n\nfunc knapsack(totalItems int, maxCapacity int, values []int, weights []int) int {\n\tif totalItems <= 0 || maxCapacity <= 0 {\n\t\treturn 0\n\t}\n\n\tdp := make([]int, maxCapacity+1)\n\n\tfor item := 1; item <= totalItems; item++ {\n\t\tcurrentWeight := weights[item-1]\n\t\tcurrentValue := values[item-1]\n\n\t\tfor capacity := maxCapacity; capacity >= currentWeight; capacity-- {\n\t\t\tdp[capacity] = max(dp[capacity], dp[capacity-currentWeight] + currentValue)\n\t\t}\n\t}\n\n\treturn dp[maxCapacity]\n}\n\nfunc main() {\n\treader := bufio.NewReader(os.Stdin)\n\n\tn, W, v, w := readInput(reader)\n\tmaxProfit := knapsack(n, W, v, w)\n\tfmt.Printf(\"Maximum Profit: %d\\n\", maxProfit)\n}\n\nfunc max(a, b int) int {\n\tif a > b {\n\t\treturn a\n\t}\n\treturn b\n}\n\nfunc readInput(reader *bufio.Reader) (int, int, []int, []int) {\n\tvar n, W int\n\tfmt.Fscan(reader, &n, &W)\n\n\tv, w := make([]int, n), make([]int, n)\n\tfor i := 0; i < n; i++ {\n\t\tfmt.Fscan(reader, &w[i], &v[i])\n\t}\n\n\treturn n, W, v, w\n}\n"
  },
  {
    "path": "submissions/wmsbill/.nvmrc",
    "content": "v20.10.0"
  },
  {
    "path": "submissions/wmsbill/README.md",
    "content": "# wmsbill Submission\n\n## How to run\n\n- Enter this folder and run `nvm use` (or use node 20)\n- Than run `node problema_01.js {filepath}/{filename}.txt`\n- If no filepath provided, examplo_03.txt will be used.\n"
  },
  {
    "path": "submissions/wmsbill/problema_01.js",
    "content": "const fs = require(\"node:fs\");\nconst args = process.argv.slice(2);\n\nfunction parse(fileContent) {\n  const [inputConfig, ...entries] = fileContent\n    .split(\"\\n\")\n    .filter((line) => line.length > 0)\n    .map((line) => line.split(/\\W/).map(Number));\n\n  return [inputConfig[1], entries];\n}\n\nfunction main(file) {\n  const fileContent = fs.readFileSync(file, \"utf8\");\n  const [spaces, entries] = parse(fileContent);\n  const table = new Map();\n\n  entries\n    .sort((a, b) => b[1] / b[0] - a[1] / a[0])\n    .forEach(([size, value]) => {\n      if (table.has(size)) {\n        table.get(size).push(value);\n        return;\n      }\n\n      table.set(size, [value]);\n    });\n\n  const pointers = Array.from({ length: table.size + 1 }, () => 0);\n  const profitTable = [{ value: 0, pointers }];\n\n  for (let i = 1; i <= spaces; i++) {\n    let maxProfit = { value: 0, pointers: [] };\n\n    for (const [size, items] of table) {\n      const lastProfit = profitTable[i - size];\n\n      if (!lastProfit) {\n        break;\n      }\n\n      const value = items[lastProfit.pointers[size]] ?? 0;\n      const profit = lastProfit.value + value;\n\n      if (profit > maxProfit.value) {\n        const newPointers = lastProfit.pointers.slice();\n        newPointers[size]++;\n        maxProfit = {\n          value: profit,\n          pointers: newPointers,\n        };\n      }\n    }\n\n    profitTable[i] = maxProfit;\n  }\n\n  return profitTable.at(-1).value;\n}\n\nconst result = main(\n  args[0] ?? \"./resources/instances/problem_01/exemplo_03.txt\"\n);\nconsole.log(result);\n"
  },
  {
    "path": "submissions/zeroskullx/.nvmrc",
    "content": "v20.10.0\r\n"
  },
  {
    "path": "submissions/zeroskullx/.temp",
    "content": "//RAW\r\n\r\nfunction maxCoinsX(seeds, W) {\r\n  const n = seeds.length;\r\n\r\n  // Inicializando a matriz para armazenar as soluções parciais\r\n  const mtz = new Array(n + 1).fill(0).map(() => new Array(W + 1).fill(0));\r\n\r\n  //console.log(\"mtz:\", mtz);\r\n\r\n  // Preenchendo a matriz usando prog dinâmica\r\n  for (let i = 1; i <= n; i++) {\r\n    const wi = seeds[i - 1].spaceRequired;\r\n    const vi = seeds[i - 1].coins;\r\n\r\n    for (let j = 1; j <= W; j++) {\r\n      // Verificando se podemos incluir a semente i na plantação\r\n      if (wi <= j) {\r\n        // Se for possível incluir a semente i na plantação, então o valor máximo obtido é o máximo entre:\r\n        // 1) o valor máximo obtido sem incluir a semente i na plantação e\r\n        // 2) o valor máximo obtido incluindo a semente i na plantação\r\n        mtz[i][j] = Math.max(mtz[i - 1][j], mtz[i - 1][j - wi] + vi);\r\n      } else {\r\n        // Se não for possível incluir a semente i na plantação, então o valor máximo obtido é o mesmo da semente anterior\r\n        mtz[i][j] = mtz[i - 1][j];\r\n      }\r\n    }\r\n  }\r\n\r\n  // Reconstruindo a solução para determinar as sementes escolhidas\r\n  const selectedSeeds = [];\r\n  let ni = n;\r\n  let Wj = W;\r\n  while (ni > 0 && Wj > 0) {\r\n    if (mtz[ni][Wj] !== mtz[ni - 1][Wj]) {\r\n      selectedSeeds.push(seeds[ni - 1].seed);\r\n      Wj -= seeds[ni - 1].spaceRequired;\r\n    }\r\n    ni--;\r\n  }\r\n\r\n  // Retornando o valor máximo obtido e a ou as sementes escolhidas\r\n  return { maxValue: mtz[n][W], selectedSeeds };\r\n}\r\n\r\n\r\n// // EXEMPLO DE USO\r\n// // # Sementes disponíveis\r\n// const seeds = [\r\n//   { seed: \"cafe\", coins: 150, spaceRequired: 1 },\r\n//   { seed: \"arroz\", coins: 260, spaceRequired: 2 },\r\n//   { seed: \"cenoura\", coins: 100, spaceRequired: 1 },\r\n//   // { seed: 'batata', coins: 100,  spaceRequired: 2 },\r\n//   // { seed: 'feijão', coins: 160,  spaceRequired: 1 },\r\n// ];\r\n// // # Espaço disponível na plantação\r\n// const W = 2;\r\n\r\n// const result = maxCoins(seeds, W);\r\n\r\n// const seedLabel =\r\n//   result.selectedSeeds.length > 1 ? \"Sementes escolhidas\" : \"Semente escolhida\";\r\n\r\n// console.log(\r\n//   `${seedLabel}: ${result.selectedSeeds.join(\", \")}. Valor máximo obtido: ${result.maxValue\r\n//   }`\r\n// );\r\n\r\n//SORT SOMENTE PARA FINS DE TESTE\r\n// Função para ordenar as sementes,\r\n// Exemplo:  ['11', '9', 'batata', '1', 'arroz'] = ['1', '9', '11', 'arroz', 'batata']\r\n"
  },
  {
    "path": "submissions/zeroskullx/README.md",
    "content": "# Zeroskullx\r\n\r\n## Problema 01: Lucro de Plantação no Stardew Valley\r\n\r\n**🛠 Getting Started**\r\n\r\n- JavaScript\r\n- Node v20.10.0\r\n\r\n**🚀 Run problem**\r\n\r\n```bash\r\nnode problema-01 ../../resources/instances/problem_01/exemplo_01.txt\r\n```\r\n\r\nor\r\n\r\n```bash\r\nnode problema-01 ../../resources/instances/problem_01/exemplo_01.txt -s\r\n```\r\n\r\n_Utilize -S para visualizar as sementes plantadas._\r\n\r\n## Algoritmo de Programação Dinâmica\r\n\r\n\"Programação Dinâmica é uma técnica de otimização que resolve problemas dividindo-os em subproblemas menores e resolvendo cada subproblema apenas uma vez.\"\r\n\r\nIniciei o processo criando uma matriz para armazenar as sementes válidas. Além disso, levei a análise um passo adiante ao incluir as sementes plantadas, junto com o valor gerado por elas. No entanto, antes de chegar a esses resultados, elaborei um array de sementes com base nos exemplos do arquivo de texto. Isso foi feito para proporcionar uma compreensão mais aprofundada do algoritmo que seria aplicado às sementes.\r\n\r\n```typescript\r\n[\r\n  {\r\n    seed: string, //nome da semente baseado no index da linha\r\n    spaceRequired: number,\r\n    coins: number,\r\n  },\r\n];\r\n```\r\n\r\n_Não usei typescript, somente para fins ilustrativos_\r\n\r\n## Desempenho do Algoritmo\r\n\r\nO desempenho do algoritmo pode depender de diversos fatores, incluindo o tamanho dos dados de entrada. O algoritmo `maxCoins` é uma implementação de um problema clássico chamado \"Problema da Mochila\" usando programação dinâmica. A complexidade de tempo típica do algoritmo é da ordem de O(n \\* W), onde \"n\" é o número de sementes e \"W\" é a capacidade total dos espaços disponíveis.\r\n\r\n## Resultado Template\r\n\r\n```bash\r\n◽ Solução: 407\r\n\r\nor\r\n\r\n🌱 Sementes plantadas: [2, 3, 4, 6, 8, 9]\r\n◽ Solução: 407\r\n```\r\n"
  },
  {
    "path": "submissions/zeroskullx/problema-01.js",
    "content": "const args = process.argv.slice(2);\r\nconst arg0 = args[0];\r\nconst arg1 = args[1];\r\n\r\n// ALGORITMO DE PROGRAMAÇÃO DINÂMICA PARA\r\n// RESOLVER O PROBLEMA DA PLANTAÇÃO DE SEMENTES\r\nfunction maxCoins(seeds, W) {\r\n  const n = seeds.length;\r\n\r\n  const mtz = Array.from({ length: n + 1 }, () => Array(W + 1).fill(0));\r\n\r\n  for (let i = 1; i <= n; i++) {\r\n    const { spaceRequired: wi, coins: vi } = seeds[i - 1];\r\n\r\n    for (let j = 1; j <= W; j++) {\r\n      mtz[i][j] = Math.max(\r\n        mtz[i - 1][j],\r\n        wi <= j ? mtz[i - 1][j - wi] + vi : 0\r\n      );\r\n    }\r\n  }\r\n\r\n  const selectedSeeds = [];\r\n  for (let ni = n, Wj = W; ni > 0 && Wj > 0; ni--) {\r\n    if (mtz[ni][Wj] !== mtz[ni - 1][Wj]) {\r\n      selectedSeeds.push(seeds[ni - 1].seed);\r\n      Wj -= seeds[ni - 1].spaceRequired;\r\n    }\r\n  }\r\n\r\n  return { maxValue: mtz[n][W], selectedSeeds };\r\n}\r\n\r\n//CONSTRUÇÃO DOS ARQUIVOS PARA TESTES\r\nconst fs = require(\"fs\");\r\n\r\nfunction buildInventory(filename) {\r\n  if (!fs.existsSync(filename)) {\r\n    console.error(`Arquivo ${filename} não encontrado.`);\r\n    return;\r\n  }\r\n\r\n  const content = fs.readFileSync(filename, \"utf-8\");\r\n\r\n  const lines = content.trim().split(\"\\n\");\r\n\r\n  const [totalSeeds, availableSpace] = lines[0].split(/\\s+/).map(Number);\r\n\r\n  //Escolhas, pqn?! Mesmo diminuindo o desempenho,\r\n  //coloquei uma validação aqui.\r\n  const seeds = lines.slice(1).map((line, index) => {\r\n    const [spaceRequired, coins] = line.split(/\\s+/).map(Number);\r\n    if (isNaN(spaceRequired) || isNaN(coins)) {\r\n      return null\r\n    }\r\n\r\n    return { seed: `${index + 1}`, coins, spaceRequired };\r\n  }).filter(seed => seed !== null);\r\n\r\n  const results = maxCoins(seeds, availableSpace);\r\n\r\n  echoResult(results);\r\n  //return { totalSeeds, availableSpace, seeds };\r\n}\r\n\r\n//IMPRIMIR O RESULTADO\r\n// # Organizar as sementes em ordem crescente\r\nconst sortSeeds = (seeds) => {\r\n  seeds.sort((a, b) => {\r\n    if (!isNaN(a) && !isNaN(b)) {\r\n      return parseInt(a, 10) - parseInt(b, 10);\r\n    }\r\n    if (!isNaN(a)) {\r\n      return -1;\r\n    }\r\n    if (!isNaN(b)) {\r\n      return 1;\r\n    }\r\n    return a.localeCompare(b);\r\n  });\r\n  return seeds;\r\n};\r\n\r\nconst echoResult = (result) => {\r\n\r\n  const seedLabel =\r\n    result.selectedSeeds.length > 1 ? \"Sementes plantadas\" : \"Semente plantada\";\r\n\r\n\r\n  if (arg1?.toLowerCase() === \"-s\")\r\n    console.log(\r\n      `🌱 ${seedLabel}: [${sortSeeds(result.selectedSeeds).join(\", \")}].`\r\n    );\r\n  console.log(`◽ Solução: ${result.maxValue}`);\r\n};\r\n\r\n//EXEC\r\nbuildInventory(arg0);\r\n"
  },
  {
    "path": "submissions/zeroskullx/test.txt",
    "content": "3 2\r\n1  150\r\n2  260\r\n1  100\r\n"
  }
]