Differences

This shows you the differences between two versions of the page.

programiranje:python_challenge:nivo_2 [2009/11/23 09:05] (current)
delboy created
Line 1: Line 1:
 +===== Python Challenge - Nivo 2 =====
 +U [[http://www.pythonchallenge.com/pc/def/ocr.html|ovom nivou]] text ispod slike kaže da treba pogledati source. U source-u ima mnogo đubreta i rečenica koja kaže da treba potražiti karaktere koji se retko pojavljuju. Text iz source-a sam stavio u zaseban file radi preglednosti programa i fajl se zove //text_2.txt//.
 +<code python>
 +#!/usr/bin/env python
 +
 +import string
 +
 +f = open("text_2.txt", "r")
 +text = f.read()
 +
 +rez = [i for i in text if i in string.letters]
 +
 +print ''.join(rez) + ".html"
 +</code>
 +
 +**Rešenje**: http://www.pythonchallenge.com/pc/def/equality.html
 
programiranje/python_challenge/nivo_2.txt · Last modified: 2009/11/23 09:05 by delboy
 
Except where otherwise noted, content on this wiki is licensed under the following license:CC Attribution-Noncommercial-Share Alike 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki