₦airaland Forum

Welcome, Guest: RegisterLoginWith GoogleTrendingRecentNew

Stats: 3,331,281 members, 8,449,566 topics. Date: Wednesday, 22 July 2026 at 01:58 AM

Toggle theme

Jacob05's Posts

Nairaland ForumJacob05's ProfileJacob05's Posts

1 2 3 4 5 6 7 8 ... 33 34 35 36 37 (of 37 pages)

ProgrammingRe: Java Rules,who Thinks Otherwise? by jacob05(m): 12:17pm On Nov 25, 2008
Java sucks tongue tongue



PYTHON RULES cool cool
PhonesRe: n/a by jacob05(m): 11:52am On Nov 24, 2008
Meaning: e don finish grin
PhonesRe: n/a by jacob05(m): 11:51am On Nov 24, 2008
Meaning: e don finish grin
PhonesRe: n/a by jacob05(m): 10:15am On Nov 24, 2008
@POSTER



Don't mind toluxa1 PYTHON is also a very powerful programming language which can do most things is so call JAVA can do and do it prefectly and you can write codes in python 5 times shorter than java and produce thesame result. It don't matter about the programming language you are using what matters is the "PRODUCTIVITY" which i believe python is. And about the FB thing it as lead me to the creation of my first two programs  (I am a beginner ) first is the MTN trick download converter with help me to download files on my pc which made the mtn @ trick download url to download files by removing the google.com/gwt/n?u=http:// and replacing some google codes like %2f which is /. Second is my desktop file manager which came about when i am having problems with too much downloaded files on my desktop and i have to move each downloaded file format to a specific folder and it as helped me alot in managing my desktop to see the source code go to programming challenge thread.
ProgrammingRe: Programming Challenge(python,java,vb,.net: Etc) by jacob05(op): 9:08pm On Nov 23, 2008
Well it seems no body is willing to answer my question cry

undecidedwell i reveal my source code in PYTHON PROGRAMMING LANGUAGE

but this file manager suchs for '.txt','.py','.doc','.java','.pdf','.htm' and suchs the Desktop

i created this Desktop manager as a result of a problem of having too much files on my desktop
since all my internet downloads are downloaded on desktop and i made it a challenge for myself
not to manually move all the desktop files since they are many and different file format so that bring
about these my desktop manager.





import os
import shutil
print '*******WELCOME TO THESE POWERFUL Desktop Manager*******'
print
folder='D:\Documents and Settings\OYEBANJI\Desktop'
os.chdir(folder)

cwd=os.getcwd()
print '******* Current Direntory is '+cwd+' ********'

for treedir in ('DesktopHTM_FILES','DesktopPAGES','DesktopTEXT','DesktopPYTHON','DesktopJAVA','DesktopPDF','DesktopDOC'):
if treedir in os.listdir(cwd):
print '*****PATH '+ treedir + ' Already Exist****'
print
if treedir not in os.listdir(cwd):
print '**** Creating '+ treedir+' Direntory*****'
os.mkdir(treedir)
print "***** PATH CREATED ******"

files=[]
for i in ('.txt','.py','.doc','.java','.pdf','.htm'):
for filename in os.listdir(folder):

if filename.find(i)>-1:

files+=[folder + "\\" + filename]

if len(files) > 0:
for filename in files:
if os.path.splitext(filename)[1].upper()[1:]== 'HTM' or 'HTML':

j = os.path.split(filename)[1]

if j in os.listdir('DesktopHTM_FILES'):

print j +' Already in '+ 'DesktopHTM_FILES'

print

if j not in os.listdir('DesktopHTM_FILES'):

q = shutil.move(filename,'DesktopHTM_FILES')

print "*** MOVED " + filename + " TO " + 'DesktopHTM_FILES'

if os.path.splitext(filename)[1].upper()[1:]== 'TXT':

j = os.path.split(filename)[1]

if j in os.listdir('DesktopTEXT'):

print j +' Already in '+ 'DesktopTEXT'

print

if j not in os.listdir('DesktopTEXT'):

q = shutil.move(filename,'DesktopTEXT')

print "*** MOVED " + filename + " TO " + 'DesktopTEXT'
if os.path.splitext(filename)[1].upper()[1:]== 'PY':

j = os.path.split(filename)[1]

if j in os.listdir('DesktopPYTHON'):

print j +' Already in '+ 'DesktopPYTHON'

print

if j not in os.listdir('DesktopPYTHON'):

q = shutil.move(filename,'DesktopPYTHON')

print "*** MOVED " + filename + " TO " + 'DesktopPYTHON'
if os.path.splitext(filename)[1].upper()[1:]== 'JAVA':

j = os.path.split(filename)[1]

if j in os.listdir('DesktopJAVA'):

print j +' Already in '+ 'DesktopJAVA'

print

if j not in os.listdir('DesktopJAVA'):

q = shutil.move(filename,'DesktopJAVA')

print "*** MOVED " + filename + " TO " + 'DesktopJAVA'
if os.path.splitext(filename)[1].upper()[1:]== 'PDF':

j = os.path.split(filename)[1]

if j in os.listdir('DesktopPDF'):

print j +' Already in '+ 'DesktopPDF'

print

if j not in os.listdir('DesktopPDF'):

q = shutil.move(filename,'DesktopPDF')

print "*** MOVED " + filename + " TO " + 'DesktopPDF'
if os.path.splitext(filename)[1].upper()[1:]== 'DOC':

j = os.path.split(filename)[1]

if j in os.listdir('DesktopDOC'):

print j +' Already in '+ 'DesktopDOC'

print

if j not in os.listdir('DesktopDOC'):

q = shutil.move(filename,'DesktopDOC')

print "*** MOVED " + filename + " TO " + 'DesktopDOC'
raw_input('ENTER ANY KEY TO EXIT> ')


if len(files) < 1:
print 'No File FOUND'
raw_input('ENTER ANY KEY TO EXIT> ')



#print filename
ProgrammingRe:python Programming by jacob05(op): 10:46pm On Nov 19, 2008
solution 2

a=int(raw_input("enter score: " ))

if 59 < a > 100 :
print " Input Greater Than 100 or Input Less the 60"
else:
if a in range(90,101):
print " Your Grade is A"
if a in range(80,90):
print "Your Grade is B "
if a in range(70,80):
print "Your Grade is C"
if a in range(61, 70):
print "Your Grade is D"
if a==60:
print "Your Grade is F"
ProgrammingRe: Python Programming by jacob05(op): 10:44pm On Nov 19, 2008
solution 2

a=int(raw_input("enter score: " ))

if 59 < a > 100 :
print " Input Greater Than 100 or Input Less the 60"
else:
if a in range(90,101):
print " Your Grade is A"
if a in range(80,90):
print "Your Grade is B "
if a in range(70,80):
print "Your Grade is C"
if a in range(61, 70):
print "Your Grade is D"
if a==60:
print "Your Grade is F"
ProgrammingRe: Python Programming by jacob05(op): 9:51pm On Nov 19, 2008
Solution (CORRECT)

a=input("enter score: " )

grade={5:'A',4:'B',3:'C',2:'D',1:'E',0:'F'}

if a > 5:
print 'Out of Grade Range'
else:
B=grade[a]
print B


i will be solving the other one's later
ProgrammingRe: Python Programming by jacob05(op): 12:06pm On Nov 19, 2008
Hi to all am jacob and am 17 with a bit of programming experience that i have i think i can solve all your questions





Solution 1


a=input("enter score: " )

grade=[5:A,4:B,3:C,2cheesy,1:E,0:F]


B=grade.keys(a)

print B




pardon me if these is not correct or properly stated cos am using my phone(free browsing) if it isn't correct it might be the area of B=grade.keys(a) i will revise when i get on my pc
ProgrammingRe: Python Programming by jacob05(op): 12:05pm On Nov 19, 2008
Hi to all am jacob and am 17 with a bit of programming experience that i have i think i can solve all your questions





Solution 1


a=input("enter score: " )

grade=[5:A,4:B,3:C,2cheesy,1:E,0:F]


B=grade.keys(a)

print B




pardon me if these is not correct or properly stated cos am using my phone(free browsing) if it isn't correct it might be the area of B=grade.keys(a) i will revise when i get on my pc
ProgrammingProgramming Challenge(python,java,vb,.net: Etc) by jacob05(op): 9:37am On Nov 19, 2008
Hi nairalanders, am jacob a beginner in python programming language. I want this thread to be a of source competition or challenge in which a user post a question
(which he or she can and have solve) and wait for answers from other posters and after the question is answered he reveal the source code and if the question again
is not answered in TWO WEEKS he reveal the answer.

NOTE: The question can be solved with any programming language sofar as the answer is correct and multiple answers are also allowed.   

                                       
First challenge: Create a file manager that searches a given system location for .mp3,.pdf,.zip,.doc,.txt,.html,.java,.py,.php,.jar files and extract the files from the given
location  and create folders to save each seperate file format in location of your choice.FINISH:-)                                             

simplehuh  Well like i have said earlier i am a beginner and i am not to ask hard questions that i can't solve. And forever me of how this post is written because
i am using my phone(free browse). 

SO GOOD LUCK TO YOU ALL
PhonesConfig nokia 3110 Using Zain With Opera by jacob05(op): 1:59pm On Nov 15, 2008
Using Zain With Opera:create An Access Point By Going To Settings-->config-->presonal Config --> add new --> access point
NOTE:DON'T CHOOSE WEB CAUSE APP'S{OPERA} CONNECT WITH ACCESS POINT After that put the zain trick:apn:mms.ng.zain.com user&pass:mms DONE!
ProgrammingPython Programming by jacob05(op): 6:43pm On Sep 27, 2008
>>>print "Hello, World"


>>> print "Has any body tried his or her hands in python and what are your experiences and views using it"
PhonesRe: How To Use Your Mobile Phone As A Modem (with Images) by jacob05(m): 12:46pm On Jul 22, 2008
at want cost can i use this services or is it free grin with no charge huh

1 2 3 4 5 6 7 8 ... 33 34 35 36 37 (of 37 pages)