mirror of
https://github.com/TheAlgorithms/C.git
synced 2026-02-04 05:44:35 +00:00
[PR #518] [MERGED] Project euler/master #938
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/TheAlgorithms/C/pull/518
Author: @kvedala
Created: 3/30/2020
Status: ✅ Merged
Merged: 4/13/2020
Merged by: @StepfenShawn
Base:
master← Head:project_euler/master📝 Commits (10+)
0d1eb35add input data as an ASCII text file6fa88februte-force method - O(n^2)6dd8824an optimized solution - O(n) complexity89a0e98updating DIRECTORY.md01c80f1updating DIRECTORY.md30bc9a2brute force method for Euler# 09ebb887aupdating DIRECTORY.md51115bfoptimized solution using only one loop2ab1e55Merge branch 'project_euler/problem_09' of github.com:kvedala/C into project_euler/problem_09458404aupdating DIRECTORY.md📊 Changes
15 files changed (+848 additions, -0 deletions)
View changed files
📝
.gitignore(+2 -0)📝
DIRECTORY.md(+19 -0)➕
project_euler/Problem 08/digits.txt(+20 -0)➕
project_euler/Problem 08/sol1.c(+100 -0)➕
project_euler/Problem 08/sol2.c(+117 -0)➕
project_euler/Problem 09/sol1.c(+18 -0)➕
project_euler/Problem 09/sol2.c(+38 -0)➕
project_euler/Problem 10/sol1.c(+37 -0)➕
project_euler/Problem 10/sol2.c(+51 -0)➕
project_euler/Problem 12/sol1.c(+46 -0)➕
project_euler/Problem 13/num.txt(+100 -0)➕
project_euler/Problem 13/sol1.c(+136 -0)➕
project_euler/Problem 14/sol1.c(+74 -0)➕
project_euler/Problem 15/sol1.c(+35 -0)➕
project_euler/Problem 16/sol1.c(+55 -0)📄 Description
Project Euler solutions
Problem 08
sol1.c1uses brute-force method, reads the digitsnum_digitstimes. It requiresnum_digits^2multiplication operations.sol2.cis optimized and requires only one read andnum_digitsmultiplications andnum_digitsdivisions.Problem 09
Two solution -
sol1.cuses brute force search andsol2.csimplifies the search by creating relations of two unknownsbandcin terms of the search parametera.Problem 10
.gitignoreto ignore build outputs (*.exe files on windows OS) and visual studio code config folder.sol1.cuses brute force sequential method to search for primes and requires multiple loops.sol2.cuses Sieve of Eratosthenes to simplify the search for primes.Problem 12
Problem 13
Problem 14
Problem 15
Problem 16
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.