Programming 2

Put your programming skills to the test in these challenges.

Re: Programming 2

Post by ZyrgEr on Sat Oct 06, 2012 3:18 pm
([msg=69982]see Re: Programming 2[/msg])

gotta love perl's getPixel 8-)
ZyrgEr
New User
New User
 
Posts: 8
Joined: Tue Sep 11, 2012 9:41 am
Blog: View Blog (0)


Re: Programming 2

Post by SleepProgger on Sat Oct 06, 2012 5:57 pm
([msg=69987]see Re: Programming 2[/msg])

Why using socks and stuff if one could simply use js for this ?
.. Canvas are great ;)
SleepProgger
New User
New User
 
Posts: 2
Joined: Thu Aug 05, 2010 10:19 am
Blog: View Blog (0)


Re: Programming 2

Post by conscience on Sun Nov 04, 2012 2:15 pm
([msg=70550]see Re: Programming 2[/msg])

SleepProgger wrote:Why using socks and stuff if one could simply use js for this ?
.. Canvas are great ;)


Exactly
Let him who has understanding recount the number of the beast, for it is a human number: His number is 0x029A.
conscience
Poster
Poster
 
Posts: 248
Joined: Thu Jan 08, 2009 9:05 pm
Location: 127.0.0.1
Blog: View Blog (0)


Re: Programming 2

Post by RootCrisis on Tue Jan 01, 2013 12:19 am
([msg=71928]see Re: Programming 2[/msg])

I'm getting a little frustrated. I built a decoder in java that parses the png image, converts it to morse code and maps the morse to characters. I'm getting valid 10 alphanumeric character strings. However, I can't seem to get the challenge to accept any inputs. I'm getting them in before time has expired and I've tried both upper and lower case. Is there a specific format I should use? Should I leave spaces between each character?

-- Mon Dec 31, 2012 11:46 pm --

(facepalm)

I was throwing away the first morse symbol, throwing off the first character by a single dit/dash. Guess I should've worked a little more before posting. Thanks anyway, peoples.
RootCrisis
New User
New User
 
Posts: 5
Joined: Sat Nov 05, 2011 11:54 pm
Blog: View Blog (0)


Re: Programming 2

Post by Pubezilla on Fri Apr 19, 2013 11:17 pm
([msg=75239]see Re: Programming 2[/msg])

If you are submitting the decoded alphanumeric and it isn't working try checking for spaces at the end of the answer. That was my problem. Highlighting the text for the Copy paste grabbed a couple of spaces at the end of text.
Pubezilla
New User
New User
 
Posts: 1
Joined: Thu Apr 18, 2013 3:21 am
Blog: View Blog (0)


Re: Programming 2

Post by -Ninjex- on Mon Jul 08, 2013 1:20 pm
([msg=76385]see Re: Programming 2[/msg])

Well, I am newer(ish) to programming, and this was a fun little challenge.

For you php lovers out there, like myself, I managed to complete this using the php5's gd library, which contained everything I needed to get this to work.

imagecreatefrompng()
imagesx()
imagesy()
imagescolorat()

Using those with a couple for loops and a bit of exploding, and two arrays, and you have yourself a victory dance.
If you're not willing to learn, no one can help you. If you're determined to learn, no one can stop you.⠠⠵
The absence of evidence is not evidence of absence.
I can explain it for you, but I can't understand it for you.
User avatar
-Ninjex-
Addict
Addict
 
Posts: 1209
Joined: Sun Sep 02, 2012 8:02 pm
Blog: View Blog (0)


Re: Programming 2

Post by razor9199 on Thu Apr 10, 2014 6:39 am
([msg=80201]see Re: Programming 2[/msg])

hi guys, i made a matlab script for that mission but the answer is never correct for the site, (i compared it with some morse translators online and it results correct).
the answer must be lowercase? character / is a character space, right?
thanks for the answers
razor9199
New User
New User
 
Posts: 1
Joined: Thu Apr 10, 2014 6:31 am
Blog: View Blog (0)


Re: Programming 2

Post by -Ninjex- on Fri Apr 11, 2014 8:52 am
([msg=80222]see Re: Programming 2[/msg])

Edited
razor9199 wrote:hi guys, i made a matlab script for that mission but the answer is never correct for the site, (i compared it with some morse translators online and it results correct).

Are you sure you are getting the correct offset values of each white pixel?
If the morse decryption is working properly, this is likely your issue.

razor9199 wrote:the answer must be lowercase?

It's been so long, but if I recall correctly, I used uppercase.
However, nothing is stopping you from trying both.

I just gave this mission a go again and completed it. The answer works in either uppercase or lowercase.
This means that your issue is incorrect counting of the white pixels.
Keep in mind that there are a couple little tricky pixels at first that are close to white, but they are not.
Here is a snippet
Code: Select all
Pixel red=0, green=0, blue=0, opacity=65535 at offset value: 7
Pixel red=0, green=0, blue=0, opacity=65535 at offset value: 16
Pixel red=65535, green=65535, blue=65535, opacity=0 at offset value: 23
Pixel red=65535, green=65535, blue=65535, opacity=0 at offset value: 45
Pixel red=65535, green=65535, blue=65535, opacity=0 at offset value: 45


razor9199 wrote:/ is a character space, right?

Correct, however completing this mission again, I noticed that none of the ASCII values offset decoded from the morse cipher text evaluated to the '/' character. It will simply be the ASCII value of 32 a regular white space character, not the ASCII value of 47 or '/'
If you're not willing to learn, no one can help you. If you're determined to learn, no one can stop you.⠠⠵
The absence of evidence is not evidence of absence.
I can explain it for you, but I can't understand it for you.
User avatar
-Ninjex-
Addict
Addict
 
Posts: 1209
Joined: Sun Sep 02, 2012 8:02 pm
Blog: View Blog (0)


Re: Programming 2

Post by cgen on Thu Jun 26, 2014 4:51 am
([msg=81750]see Re: Programming 2[/msg])

After completing the program, I couldn't figure out why the password generated wasn't working... after a lot of investigation and careful examination... I realize was a counting issue.

I want to share my problem and solution with you guys, for people that might have come across a similar problem.

At first, I was getting ,(comma) and -(dash) like some of you, then I quickly realize it was a offset issue.

I did a quick and dirty way of fixing it by starting my counts at 1 instead of zero to try and fix this offset problem, then the real problem begin. It was generating passwords that looks correct, but wasn't going through....

The problem was... because I started my count at 1, the first character was always offset by one.

After finally realizing the problem then I figure out that counting starts one pixel, but we need to count the white pixel itself when we are looping through... that's what I miscounted.

When we are creating loop, we might have logics that cause us to mis counting the white pixel itself, which will generate similar answers, but incorrect.

Hope this rambling help resolve issues for some of you.
cgen
New User
New User
 
Posts: 1
Joined: Mon Jun 22, 2009 12:22 am
Blog: View Blog (0)


Previous

Return to Programming

Who is online

Users browsing this forum: No registered users and 0 guests