it probably
Dec. 8th, 2012 12:35 pmtook about the same time as renaming the files individually (since i had to look up a bit of syntax and stuff)
but such a satisfying feeling when you press enter and...
fwoom@sanitizer:~/cs188$ python lala.py
FA12 cs188 lecture 26 -- conclusion (6PP).4862189c2bf7.pdf
FA12 cs188 lecture 24 -- computer vision and robotics (6PP).611ed07dede8.pdf
FA12 cs188 lecture 2 -- uninformed search (6PP).e26b41765d01.pdf
FA12 cs188 lecture 25 -- advanced applications (nlp and cars) (6PP).ee89d5b99dca.pdf
FA12 cs188 lecture 3 -- a-star search (6PP).3c9afbc24b2b.pdf
FA12 cs188 lecture 4 -- CSPs (6PP).8550c2ea07f9.pdf
FA12 cs188 lecture 16 -- bayes nets sampling (6PP).691e51221d2e.pdf
FA12 cs188 lecture 8 -- MDPs (6PP).e0a0bf8fa583.pdf
FA12 cs188 lecture 7 -- expectimax search (6PP).8c173d668739.pdf
FA12 cs188 lecture 23 -- decision trees (6PP).55b77dfccdd6.pdf
FA12 cs188 lecture 1 -- introduction (6PP).f29e487a9adb.pdf
FA12 cs188 lecture 11 -- reinforcement learning II (6PP).a280bb1a6f6b.pdf
FA12 cs188 lecture 9 -- MDPs II (6PP).990ecfd12a24.pdf
FA12 cs188 lecture 10 -- reinforcement learning (6PP).34d0e162849c.pdf
FA12 cs188 lecture 13 -- bayes nets (6PP).3c28c589fae3.pdf
FA12 cs188 lecture 5 -- CSPs II (6PP).5cfbeb914c5d.pdf
FA12 cs188 lecture 19 -- speech (6PP).e599224a0384.pdf
FA12 cs188 lecture 20 -- naive bayes (6PP).8054464b647e.pdf
FA12 cs188 lecture 17 -- decision diagrams, vpi (6PP).599803417138.pdf
FA12 cs188 lecture 12 -- probability (6PP).6fd83b78fc79.pdf
FA12 cs188 lecture 21 -- perceptron (6PP).8ce680758421.pdf
FA12 cs188 lecture 15 -- bayes nets inference (6PP).68505909c0c7.pdf
FA12 cs188 lecture 6 -- adversarial search (6PP).4e6f9f89bad4.pdf
FA12 cs188 lecture 22 -- clustering (6PP).63c108b44f13.pdf
FA12 cs188 lecture 18 -- HMMs (6PP).4211bf9d3733.pdf
lecture 13 -- bayes nets.pdf
lecture 24 -- computer vision and robotics.pdf
lecture 7 -- expectimax search.pdf
lecture 26 -- conclusion.pdf
lecture 20 -- naive bayes.pdf
practice_midterm_1_solutions.7cc2ee3beba3.pdf
lecture 19 -- speech.pdf
lecture 3 -- a-star search.pdf
lecture 12 -- probability.pdf
lecture 14 -- baye.pdf
lala.py
lecture 11 -- reinforcement learning II.pdf
lecture 8 -- MDPs.pdf
lecture 17 -- decision diagrams, vpi.pdf
lecture 16 -- bayes nets sampling.pdf
lecture 21 -- perceptron.pdf
lecture 4 -- CSPs.pdf
fa11-midterm-solutions.pdf
lecture 22 -- clustering.pdf
lecture 18 -- HMMs.pdf
lecture 6 -- adversarial search.pdf
lecture 10 -- reinforcement learning.pdf
lecture 25 -- advanced applications (nlp and cars).pdf
midterm-solutions-sp11.pdf
midterm-sp11.pdf
lecture 23 -- decision trees.pdf
lecture 2 -- uninformed search.pdf
lecture 5 -- CSPs II.pdf
fa11-midterm.pdf
lecture 15 -- bayes nets inference.pdf
lecture 9 -- MDPs II.pdf
lecture 1 -- introduction.pdf
import os
for i in os.listdir("."):
if i.startswith("FA12 CS188"):
os.rename(i, i[11:len(i)-21]+".pdf")
for i in os.listdir("."):
print i
<3
but such a satisfying feeling when you press enter and...
fwoom@sanitizer:~/cs188$ python lala.py
FA12 cs188 lecture 26 -- conclusion (6PP).4862189c2bf7.pdf
FA12 cs188 lecture 24 -- computer vision and robotics (6PP).611ed07dede8.pdf
FA12 cs188 lecture 2 -- uninformed search (6PP).e26b41765d01.pdf
FA12 cs188 lecture 25 -- advanced applications (nlp and cars) (6PP).ee89d5b99dca.pdf
FA12 cs188 lecture 3 -- a-star search (6PP).3c9afbc24b2b.pdf
FA12 cs188 lecture 4 -- CSPs (6PP).8550c2ea07f9.pdf
FA12 cs188 lecture 16 -- bayes nets sampling (6PP).691e51221d2e.pdf
FA12 cs188 lecture 8 -- MDPs (6PP).e0a0bf8fa583.pdf
FA12 cs188 lecture 7 -- expectimax search (6PP).8c173d668739.pdf
FA12 cs188 lecture 23 -- decision trees (6PP).55b77dfccdd6.pdf
FA12 cs188 lecture 1 -- introduction (6PP).f29e487a9adb.pdf
FA12 cs188 lecture 11 -- reinforcement learning II (6PP).a280bb1a6f6b.pdf
FA12 cs188 lecture 9 -- MDPs II (6PP).990ecfd12a24.pdf
FA12 cs188 lecture 10 -- reinforcement learning (6PP).34d0e162849c.pdf
FA12 cs188 lecture 13 -- bayes nets (6PP).3c28c589fae3.pdf
FA12 cs188 lecture 5 -- CSPs II (6PP).5cfbeb914c5d.pdf
FA12 cs188 lecture 19 -- speech (6PP).e599224a0384.pdf
FA12 cs188 lecture 20 -- naive bayes (6PP).8054464b647e.pdf
FA12 cs188 lecture 17 -- decision diagrams, vpi (6PP).599803417138.pdf
FA12 cs188 lecture 12 -- probability (6PP).6fd83b78fc79.pdf
FA12 cs188 lecture 21 -- perceptron (6PP).8ce680758421.pdf
FA12 cs188 lecture 15 -- bayes nets inference (6PP).68505909c0c7.pdf
FA12 cs188 lecture 6 -- adversarial search (6PP).4e6f9f89bad4.pdf
FA12 cs188 lecture 22 -- clustering (6PP).63c108b44f13.pdf
FA12 cs188 lecture 18 -- HMMs (6PP).4211bf9d3733.pdf
lecture 13 -- bayes nets.pdf
lecture 24 -- computer vision and robotics.pdf
lecture 7 -- expectimax search.pdf
lecture 26 -- conclusion.pdf
lecture 20 -- naive bayes.pdf
practice_midterm_1_solutions.7cc2ee3beba3.pdf
lecture 19 -- speech.pdf
lecture 3 -- a-star search.pdf
lecture 12 -- probability.pdf
lecture 14 -- baye.pdf
lala.py
lecture 11 -- reinforcement learning II.pdf
lecture 8 -- MDPs.pdf
lecture 17 -- decision diagrams, vpi.pdf
lecture 16 -- bayes nets sampling.pdf
lecture 21 -- perceptron.pdf
lecture 4 -- CSPs.pdf
fa11-midterm-solutions.pdf
lecture 22 -- clustering.pdf
lecture 18 -- HMMs.pdf
lecture 6 -- adversarial search.pdf
lecture 10 -- reinforcement learning.pdf
lecture 25 -- advanced applications (nlp and cars).pdf
midterm-solutions-sp11.pdf
midterm-sp11.pdf
lecture 23 -- decision trees.pdf
lecture 2 -- uninformed search.pdf
lecture 5 -- CSPs II.pdf
fa11-midterm.pdf
lecture 15 -- bayes nets inference.pdf
lecture 9 -- MDPs II.pdf
lecture 1 -- introduction.pdf
import os
for i in os.listdir("."):
if i.startswith("FA12 CS188"):
os.rename(i, i[11:len(i)-21]+".pdf")
for i in os.listdir("."):
print i
<3