Giter VIP home page Giter VIP logo

7billionhumans's Introduction

7 Billion Humans

Solutions to the challenges of the game "7 Billion Humans". Table with overview available at GitHub Pages.

Get the game from the Tomorrow Corporation Website.

Submit solution

Feel free to send pull requests with better solutions. Please add the time / speed as a comment in the source. You can use the script add_solution.py to put your solution in the right folder. It will ask you for the speed of your solution, determine the size automatically and put it in the correct directory.

7billionhumans's People

Contributors

ansvonwa avatar behrmann avatar blanvillain avatar davidgauch avatar deepaq avatar h-j-granger avatar horovtom avatar jheden avatar landfillbaby avatar lawrencelapointe avatar malled2002 avatar michaelgundlach avatar nkaabi avatar raikoug avatar soerface avatar std4453 avatar thrfirs avatar tiansh avatar tiza59 avatar yaheath 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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

7billionhumans's Issues

Display solutions in a neat graphical way

I'd love to see solutions displayed in a neat graphical way instead of the current text only form. That way it'd be far easier to read all of them.
As example show them in a way they'd be displayed in-game.

Overwriting of existing solutions faulty.

Target Size: 17
Size: 17
Target Speed: 54
Speed: 52
Copy the sourcecode to the clipboard and press enter


Saved:                                        solutions/64 - Binary Counter/size.asm
Saved:                                       solutions/64 - Binary Counter/speed.asm
Saved:                                      solutions/64 - Binary Counter/speed+size.asm

Add another source? [y/N] y
Target Size: 17
Size: 17
Target Speed: 54
Speed: 47
Copy the sourcecode to the clipboard and press enter


Saved:                                        solutions/64 - Binary Counter/size.asm
Saved:                                       solutions/64 - Binary Counter/speed.asm
Already exists, not overwriting:            solutions/64 - Binary Counter/speed+size.asm

As indicated by the output: my second solution was slightly faster but it did not overwrite the speed+size of my first attempt.

Questions

Are solutions that use pastable only commands allowed?
e.g. takefrom nw,sw,ne,se

Which solutions are considered better:
faster/shorter with a lower success rate or that with a higher success rate?

Are solutions from other repositories allowed?

Should we keep solutions that are inferior in every aspect?

What is the minimum allowed success rate for a solution?

It's amazing that after so many years you can still find new solutions. Thanks everyone

Travis fails randomly

In pull requests, skip the parts that need the GitHub API key to prevent them from failing randomly.

Keep all working approaches for solutions

There is no need to delete working solutions.
Instead, they may be helpful, if they contain different approaches. (A superseded approach may be improved so it gets better than the previously superseding one)

Speed test with partial fail

I had made a solution for Lv38 which is both shorter and faster than existed solution. But it not produce correct result every time. Should I add it? Maybe we should also keep the correct one?

Size: 14, Speed: 29, Pass: 18/25

a:
step n
if c <= mem1 or
 mem1 != datacube:
	mem1 = set c
endif
if n == wall:
	pickup mem1
	mem4 = nearest shredder
	b:
	mem2 = nearest worker
	if mem2 == nothing:
		giveto mem4
	endif
	if myitem >= mem2 or
	 myitem == nothing:
		mem4 = nearest hole
		step mem4
	endif
	jump b
endif
jump a

Build a parser for the solutions

If we have a parser, we could create a pretty rendering of the source on the website.
Also, it would come in pretty handy if someone wants to write a simulator (#3)

Solution to long?

I have a hardcoded solution for level 32, it is 210 commands long. When inputting via script an issue occures. There is some sort of reed error of the clipboard and it saves as a size 162 solution...

Speed: 33
Were there failing solutions (red bars instead of green ones)? [y/N] 
Were  there different times in different measurements? [y/N] 
Copy the sourcecode to the clipboard and press enter

line 118:10 token recognition error at: 'om'
line 118:13 token recognition error at: 'th'
line 118:15 token recognition error at: 'in'
line 118:17 token recognition error at: 'g:'
line 118:12 mismatched input 'e' expecting ':'

Saved:                                      solutions/32 - Creative Writhing/size-162_speed-33.asm
-- 7 Billion Humans (2053) --
-- 32: Creative Writhing --

if nw == wall:
	step s
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step e
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step w
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step e
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step w
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	end
else:
	if sw == datacube:
		step s
		pickup c
		write 99
		drop
		step w
		pickup c
		write 99
		drop
		step s
		pickup c
		write 99
		drop
		step s
		pickup c
		write 99
		drop
		step e
		pickup c
		write 99
		drop
		step s
		pickup c
		write 99
		drop
		step s
		pickup c
		write 99
		drop
		step s
		pickup c
		write 99
		drop
		step w
		pickup c
		write 99
		drop
		step s
		pickup c
		write 99
		drop
		step s
		pickup c
		write 99
		drop
		step e
		pickup c
		write 99
		drop
		step s
		pickup c
		write 99
		drop
		end
	endif
endif
if ne == something:
	step s
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step w
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step e
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step w
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	step s
	pickup c
	write 99
	drop
	end
endif
step s
pickup c
write 99
drop
step s
pickup c
write 99
drop
step e
pickup c
write 99
drop
step s
pickup c
write 99
drop
step s
pickup c
write 99
drop
step w
pickup c
write 99
drop
step s
pickup c
write 99
drop
step s
pickup c
write 99
drop
step s
pickup c
write 99
drop
step e
pickup c
write 99
drop
step s
pickup c
write 99
drop
step s
pickup c
write 99
drop

Use GitHub pages

Automatically build a fancy website with the solutions from the repository.

Switch to GitHub actions

Travis pipeline is not working anymore. Switch to GH actions for a reliable build of GH pages

Create a 7BH simulator

It would be nice if we could test given solutions automatically, allowing to check for correct solutions and measuring their performance. This way we could integrate CI and allow faster merge of pull requests.

I'm having trouble with add_solutions.py

I was trying to submit a better solution I found but the code seems to be having trouble finding antlr.SevenBillionHumansParser. I'm not too experienced with python and I'm not sure how to fix this.

More Random Tests and Comments

  • If speed fluctuates, add a comment with a list of results of random tests.
  • If it is known that a solution does not always work (or there may be edge cases), add a comment with successful tests vs number of tests, as mentioned in #19 .

Example:

...
-- Size: 42
-- Speed: 204
-- Speed Tests: 203, 204, 204, 205, 203, 203
-- Success Rate: 123/150
...

WebGL Requirement

WebGL not supported by all browser. There is no fallback for webGL. For such small graph webGL should not be relevant.

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.