TheAlgorithms-Ruby/project_euler
Vitor Oliveira e21120857d Clean up
2021-02-06 23:05:54 -08:00
..
problem_1 Fix Project Euler structure and DIRECTORY.md 2020-12-28 15:00:05 -08:00
problem_2 Clean up 2021-02-06 23:05:54 -08:00
problem_3 Clean up 2021-02-06 23:05:54 -08:00
problem_4 Clean up 2021-02-06 23:05:54 -08:00
problem_5 Clean up 2021-02-06 23:05:54 -08:00
problem_20 Fix Project Euler structure and DIRECTORY.md 2020-12-28 15:00:05 -08:00
problem_21 Fix Project Euler structure and DIRECTORY.md 2020-12-28 15:00:05 -08:00
problem_22 Fix Project Euler structure and DIRECTORY.md 2020-12-28 15:00:05 -08:00
README.md Positional argument should be Ruby style instead of Python 2020-12-28 09:19:04 -08:00

Project Euler

Problems are taken from https://projecteuler.net/, the Project Euler. Problems are licensed under CC BY-NC-SA 4.0.

Project Euler is a series of challenging mathematical/computer programming problems that require more than just mathematical insights to solve. Project Euler is ideal for mathematicians who are learning to code.

Solution Guidelines

Welcome to TheAlgorithms/Ruby! Before reading the solution guidelines, make sure you read the whole Contributing Guidelines as it won't be repeated in here. If you have any doubt on the guidelines, please feel free to state it clearly in an issue or ask the community in Gitter. Be sure to read the Coding Style before starting solution.

Coding Style

  • Please maintain consistency in project directory and solution file names. Keep the following points in mind:

    • Create a new directory only for the problems which do not exist yet.
    • Please name the project directory as problem_<problem_number> where problem_number should be filled with 0s so as to occupy 3 digits. Example: problem_001, problem_002, problem_067, problem_145, and so on.
  • You can have as many helper functions as you want but there should be one main function called solution which should satisfy the conditions as stated below:

    • It should contain positional argument(s) whose default value is the question input. Example: Please take a look at Problem 1 where the question is to Find the sum of all the multiples of 3 or 5 below 1000. In this case the main solution function will be solution(limit = 1000).
    • When the solution function is called without any arguments like so: solution(), it should return the answer to the problem.