Teach me how to hack this puzzle

This forum is for discussions related to the Runaway Robot puzzle
User avatar
CodeX
Posts: 350
Joined: Fri Oct 17, 2008 5:28 pm

Post by CodeX »

if looking at it as it is doesn't work anymore, try looking for underlying patterns which you can use to solve it
User avatar
laz0r
Posts: 290
Joined: Thu Feb 04, 2010 4:18 pm
Location: Within the depths of Unix

found the approach!

Post by laz0r »

It's ok, I worked it out! :D

I think that everyone who is above level 500 must have used the same approach.... and it didn't get noticlably slower either! (though simply writing those massive grids to the screen took a while!)
There is no spoon.
outboundglitch
Posts: 2
Joined: Thu Apr 15, 2010 4:56 am
Location: registry editor
Contact:

writing software

Post by outboundglitch »

to me writing software is a pain, the programming language i use is BATCH, thats how bad i am at programming, i suck at it, :oops: but i did make a batch file with login page, remote connection shutdown along with notepad, pop up maker, folder factory, it didn't take long. :P but thats the best i can do, anyone have any tips for me on writing software, or choosing the most easiest one? plz and thank you.
i wish to learn more about computers, i'm not a noob at computer hacking but i wish to learn more. i know how to hack/crack/bypass but still i feal like i dont know enouph, i know some but wish to know all :)
Karian
Posts: 75
Joined: Wed Jan 09, 2008 10:21 am

Post by Karian »

If you want to do some more programming, the easiest way is just to pick a language and play around with it. Take something that suits you, and find a tutorial for it online. People can discuss for days which is the best language to take, but for learning how to program, it is more or less the same. Once you know how to program, it is not that hard anymore to learn a new language.
outboundglitch
Posts: 2
Joined: Thu Apr 15, 2010 4:56 am
Location: registry editor
Contact:

Post by outboundglitch »

wow, thank you for the info. ill look around right now. :D
i wish to learn more about computers, i'm not a noob at computer hacking but i wish to learn more. i know how to hack/crack/bypass but still i feal like i dont know enouph, i know some but wish to know all :)
Masti6
Posts: 55
Joined: Sat May 15, 2010 12:04 pm
Location: Finland, Nurmes

Post by Masti6 »

gfoot wrote:It's pretty easy in most modern languages. e.g. in Python 2:

Code: Select all

import urllib
pagedata = urllib.urlopen("http://www.hacker.org").read().splitlines()
That should give you an array of lines.

In Python 3 it's been moved around a bit - I think you need:

Code: Select all

import urllib.request
pagedata = urllib.request.urlopen("http://www.hacker.org").read().splitlines()
But I don't have Python 3 installed, so I can't check it for sure.

Once you've got the data you'll have to parse it to extract useful things like the board size and contents, then write the fun bit of your code that figures out a good route.

It's actually probably better to do the fun bit first, though, so you can make test boards locally without having to wait for web requests from time to time. All my hacker.org solvers support this, and cache any downloads locally as well so I can replay them later - it's good to have some smaller boards available when you're profiling an algorithm and want faster results.
data = urllib.urlopen("http://www.hacker.org").read().splitlines()
AttributeError: 'module' object has no attribute 'urlopen'
and
import urllib.request
ImportError: No module named request
Python Version 2.6.5
Why ain't it working :(
Could you try to post a working code for getting data, and to read it, to use it, ... etc.
It would be good if you sent a copy of the file you used for the "Dungeon Master" so I could see what kind of approach I should take. I do not feel like asking for straight answers, but as I have no idea, and the tutorials out there ain't telling me the working answer either, could you?
Megafile works just fine, or paste the Python code in Pastebin.com and send me a link.
P.S.
Pretty please?
nighthalk
Posts: 41
Joined: Fri Jul 31, 2009 8:22 pm

Post by nighthalk »

heres a C# implimentation its for crossflip but its easy to modify for any of them, i obviously edited out stuff to make sure you get practice. i only provided necisary parts for the web interaction. technically i also changed the username password to be seperate strings im not entirly sure if it lets you build a static string dynamicly but i wanted it obvious you were suposed to put something there.

Code: Select all

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Net;
using System.IO;
namespace crossflipsolver
{
    class Program
    {
        static string username="yourusername"
        static string password="yourpassword"
        static string baseurl = "http://www.hacker.org/cross/?name="+username+"&      password="+password
        static void Main(string[] args)
        {
            HttpWebRequest myrequest = (HttpWebRequest)WebRequest.Create(baseurl);
            myrequest.Method = "GET";
            WebResponse myresponse = myrequest.GetResponse();
            StreamReader sr = new StreamReader(myresponse.GetResponseStream(), System.Text.Encoding.UTF8);
            string result = sr.ReadToEnd();
            puzzle = parseweb(result);
        }
        static string parseweb(string input) {
            //put your parsing code here, 
        }
    }
}
i also have a c++ implimentation but it spans like 12 files because i downloaded a library to do it for me... you may find one that may work at

http://www.cplusplus.com/src/
Wooshee
Posts: 2
Joined: Sat Jul 27, 2013 12:13 pm

how to become a hacker

Post by Wooshee »

MerickOWA wrote:Learn how to write a program? pick your favorite language java,c,c++,c#,ruby,python,lisp and learn how to download webpages in that language, and parse out of the html the maze data.

After that, you have to figure out how you want to solve the problem. The simplest method (but the longest) is to just search through all possible answers until you find an answer that solves the problem. (try each instruction length, and each combination of down(s) and right(s) until your robot makes it to the edge).

However, I don't think you'll get to level 513 with that method. You can either work on ways of speeding up your searching techniques and/or simplifying the problem so there are fewer possibilities to search.


Hi what book should i Begin with in order i can become a hacker please?
Wooshee
Posts: 2
Joined: Sat Jul 27, 2013 12:13 pm

Re: how to become a hacker

Post by Wooshee »

Wooshee wrote:
MerickOWA wrote:Learn how to write a program? pick your favorite language java,c,c++,c#,ruby,python,lisp and learn how to download webpages in that language, and parse out of the html the maze data.

After that, you have to figure out how you want to solve the problem. The simplest method (but the longest) is to just search through all possible answers until you find an answer that solves the problem. (try each instruction length, and each combination of down(s) and right(s) until your robot makes it to the edge).

However, I don't think you'll get to level 513 with that method. You can either work on ways of speeding up your searching techniques and/or simplifying the problem so there are fewer possibilities to search.


Hi what book should i Begin with in order i can become a hacker please?
thanks for u help and how i can get these programming languages?
Lilchen
Posts: 1
Joined: Sat Jul 20, 2013 3:47 pm

Post by Lilchen »

thanks for u help and how i can get these programming languages?
Perhaps, i'm unfriendly.. But

Try out:
http://lmgtfy.com/?q=java+for+beginners

or:

http://lmgtfy.com/?q=python+for+beginners


greetings
ervinjason
Posts: 1
Joined: Fri Mar 04, 2022 3:27 pm
Location: New York City

Post by ervinjason »

You're not supposed to solve all levels by hand...

it's virtually impossible.

For level 100 and up, you're expected to use a computer to solve this puzzle using a program that you write.

Learn how to write a program?

pick your favorite language java,c,c++,c#,ruby,python,lisp and learn how to download webpages in that language, and parse out of the html the maze data.

After that, you have to figure out how you want to solve the problem.

The simplest method (but the longest) is to just search through all possible answers until you find an answer that solves the problem. (try each instruction length, and each combination of down(s) and right(s) until your robot makes it to the edge).

However, I don't think you'll get to level 513 with that method.

You can either work on ways of speeding up your searching techniques and/or simplifying the problem so there are fewer possibilities to search.

Good luck.
Post Reply