So in my psychology class this semester the prof announces that 50% of the final exam is going to be composed of questions from the tests that we have already taken in class. She also releases electronic copies of the tests with all the answers highlighted,
I am ecstatic, my strategy for this course thus far has been to blow off every single lecture and only go to test days, which I prepare for by grabbing vocabulary terms from the chapters off the textbooks website, importing them into quizlet using their great auto import feature, and than robot-moding with their learn app.
Mmmmmm mindless repetition..........
So I try to copy and paste the tests into the auto import feature, but the formatting on the quizzes is all wonky. They were obviously made just by firing up word and abusing the tab button, and not by some automated test-making program.
It feels so good to fire off a tab press with your pinky, why not try one now?
At this point I had two options, manually copy and paste each term in to quizlet OR fire up the ol' python editor and write a script to auto format the tests. I'm pretty deep into a C.S degree but the last 6 months I've been doing web design stuff not 1337 hackers stuff so I felt pretty rusty. Using python was a gamble in terms of it taking less time that doing it manually, but it had the added benefit of me learning, soo......
Mark Zuckerburg and I both have our subconscious misogyny come to the surface when we drink. The only difference is he channels it into popular websites and I offend people at house parties
So anyway i end up with this:
+ Show Spoiler +
# text formater
file = open('quiz6.txt','r')
linecounter = 0
myString =""
for line in file:
if line[0] != "" or line[0] !="n":
print(line.strip())
linecounter+= 1
if linecounter == 3:
print("n")
linecounter = 0
file = open('quiz6.txt','r')
linecounter = 0
myString =""
for line in file:
if line[0] != "" or line[0] !="n":
print(line.strip())
linecounter+= 1
if linecounter == 3:
print("n")
linecounter = 0
So yeah I end up having to do a lot of formatting by myself, but I think it was probably marginally faster than copying and pasting it myself.Then I have a revelation.
Homie made this test in word, which means the answers weren't picked by a computer program but a person. The thinking man (misogyny) will have already come to the conclusion that means the distribution of answers would be skewed towards certain letters. To conform i wrote this guy(another misogynistic pronoun what is wrong w/ me)
+ Show Spoiler +
answers ="cbcabddbbbdbbccbbbdcadbccdabadbdadbcbababdbbbcbbacbddabcdbacbbacacdaabdaccbdcbcdcbdccabcdaddbdcdbcbcacaccdbdbcdbbcabbbdcdbacadaaadaddacadccbbcddcaccdbbacccd"
i = 0
a = 0
b = 0
c = 0
d = 0
while i < len(answers) - 1:
if answers[i] == "a":
a += 1
if answers[i] == "b":
b += 1
if answers[i] == "c":
c += 1
if answers[i] == "d":
d += 1
i = i + 1
print(answers[i])
print(a /(len(answers) - 1))
print(b /(len(answers) - 1))
print(c /(len(answers) - 1))
print(d /(len(answers) - 1))
i = 0
a = 0
b = 0
c = 0
d = 0
while i < len(answers) - 1:
if answers[i] == "a":
a += 1
if answers[i] == "b":
b += 1
if answers[i] == "c":
c += 1
if answers[i] == "d":
d += 1
i = i + 1
print(answers[i])
print(a /(len(answers) - 1))
print(b /(len(answers) - 1))
print(c /(len(answers) - 1))
print(d /(len(answers) - 1))
whose out put was:
0.1935483870967742
0.3032258064516129
0.2709677419354839
0.23225806451612904
ROFL, now I have a SICK edge on the test. Not against people that spent the 10 minutes studying instead of writing python scripts, but against the other people guessing. Also I have this scenario planned out in my head.
The Author: 'Sup Ma, I'm the guy who made the flashcards the instructor posted on the course website
Attractive young woman: Oh wow, you're like my hero. I'll bet your really well prepared!
The author: You know it. and by the way...If you don't know an answer, choose b
Attractive young woman;: what? why?
The author: Well you shouldn't trust me because I am a mysterious alpha male but......... trust the data
The author hands A.Y.W an attractive infographic on the distribution of answers, touching her hand in the process
Attractive young woman: Wow, this is really interesting
The author discretely smells hand as A.Y.W continues to read. He stops to hastily scribble on a piece of paper. Finished writing, he hands the paper to the A.Y.W
Attractive young woman: what's this?
Camera zooms in on paper on which is written "Will you go out with me? a.No b. Yes
The Author smiling: Always choose b .
Edit whoops