Giter VIP home page Giter VIP logo

projecteuler-solutions's People

Contributors

bhavitsharma avatar gitpinkrabbit avatar gzchenben avatar lucky-bai avatar mcr178 avatar phatmo123 avatar ra1u avatar ujimatsu-chiya avatar yydaily avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

projecteuler-solutions's Issues

I got a different answer for problem 165

My answer is 2868997, which is in the same ballpark as yours, but it's a different number.
Now, I don't know how you arrived at your solution, but I wrote a fairly straightforward Haskell program that generates all segments, then pairs them up and then checks each pair if they form a true intersection. It is quite slow, but I don't see how it can be incorrect.
If requested, I can show my code, it is quite short and self-explanatory.
Note that Project Nayuki does not have a solution for this problem.

Please do not post the solution before 100 people solved the problem.

This is the graph of fastest solvers of the currently-only problem that has less than 100 solvers. (Problem 696)

a

The horizontal line is the time the solution is committed. (cf08a03) The vertical axis is the time (in seconds) since the problem is posted, the horizontal axis is the number of people solved the problem.

I am not that good at statistics to see what's the probability of that happening by chance, but it is pretty clear just by looking at it.

b

If you insists on posting the answers despite PE's rules, at least don't post them before the fastest solvers table is finished.

Answer for 808

3807504276997394

I have 807 too but will wait for 100 solvers

Answer for 809

While I wait for 807 to get more solvers, here is 809:
75353432948733

Add solution hashes (and solution checker)

So users can check their solutions without spoiling them.

Here is a method to generate hashes.
First I convert Solutions.md into a machine-readable form (with unix newlines) where line n is just the solution string for problem n.

cat Solutions.md | dos2unix | tail -n +6 | head -n -2 | perl -pe 's/^[0-9]+\.//gm' | awk '{$1=$1}1' > solutions.txt

Then create a file with a md5 hash of the solution string if it exists, else a blank line.

while read -r line; do if [ -z $line ] ; then echo; else echo -n $line | md5sum | cut -f1 -d ' '; fi; done < solutions.txt > project_euler_md5.txt 

Here is the md5 list https://gist.github.com/jxu/4a36e1752a27fb6506ac0927c09bd5fb

To check your answer for problem n, you can manually hash your answer and check against the md5 file:

$ sed '10q;d' project_euler_md5.txt 
d915b2a9ac8749a6b837404815f1ae25
$ echo -n '1234' | md5sum | cut -f1 -d' '
81dc9bdb52d04dc20036dbd8313ed055

If you like the idea of adding this to the repo I can make a quick PR (probably with a python checker script for Windows friends)

Shame on you

If you posting euler project's solutions, then you completely destroy the whole idea.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.