Friday, April 7, 2006

Awk (r)ate my grades!

Erik has written a cool Grade calculator for students at Linköping University.

...this particular programmer for some reason, which to this day is still unknown, felt the need to play around a bit with awk, he created a script that could calculate his average grade. Did he do this because he was a vain man, and wanted some confirmation? Or was it simply a good way to try awk? We'll never know.


I have two questions for you Erik:

  1. Are you saving my grades when I submit them?

  2. Will you publish your average grade?



For those of you interested in my average, it has a sha1sum of d38c8664e7e51744376724c8bf146fbdf5644e61 when rounded to one decimal, go figure.

3 comments:

  1. 1. Well actually I'm saving yours. You see, the code I have published is not exactly the same as the one I using (I'm not that lazy that I've just symlinked grades.phps to grades.php). The script grades.php also contains my proprietary algorithm getSSNFromGrades() that examins the posted grades and determines the social security number. Before removing the temporary file I have this code:
    if (getSSNFromGrades($_POST['grade']) == getOlovsSSN()) {
    mail('erik@...', "Olov's grades", $_POST['grade']); // e-mail obfuscated
    }

    2. Nah, where's the fun in that? ;)

    ReplyDelete
  2. Why don't you publish your hash of it at least, you do know that sha1 is kind of cryptographically strong, don't you? ;)

    ReplyDelete
  3. blessed are the 1337, for they shall pwn the earth..

    ReplyDelete

Note: Only a member of this blog may post a comment.