Python Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming LanguagesPython Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old October 11th, 2012, 10:30 AM
FrogBox FrogBox is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2012
Posts: 3 FrogBox User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 51 m 57 sec
Reputation Power: 0
Question Learning Python/PyGame/WXPython/ect.

Hey everyone, I was wondering if someone could point me in the right direction here. I want to learn Python, Pygame, WXPython and any other Python based languages out there, I know a bit of Python (Just enough to make a calculator program(but not one with buttons)) and I know some Pygame(I can make a window and make a sprite that moves around and changes sprite for each direction(only top down, not platform)).

Can someone help me find a place where I can learn all this, I tried looking at the tutorials on the websites, but they don't seem like tutorials, they seem to be more like refrences. Also I can't get books because I spent all my money on a PyGame book that just repeats how to make a puzzle game. Anyone who can help me gets a cookie(not really)

Reply With Quote
  #2  
Old October 11th, 2012, 10:56 AM
b49P23TIvg's Avatar
b49P23TIvg b49P23TIvg is offline
Contributing User
Dev Shed Loyal (3000 - 3499 posts)
 
Join Date: Aug 2011
Posts: 3,371 b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level) 
Time spent in forums: 1 Month 2 Weeks 3 Days 11 h 35 m 33 sec
Reputation Power: 383
python is already a calculator. Show your calculator program!

In my opinion, you ought to learn python well, and learn to use some of the modules. These others you've mentioned, Pygame, WXPython, are python modules.
__________________
[code]Code tags[/code] are essential for python code!

Reply With Quote
  #3  
Old October 11th, 2012, 11:04 AM
FrogBox FrogBox is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2012
Posts: 3 FrogBox User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 51 m 57 sec
Reputation Power: 0
I'm aware that it is already basically a calculator, all I did was ask what the person would like to do and with shich numbers. Also, yes, I know they are modules, but knowing that doesnt not help me program in it. I've been trying to learn for a while but its hard to find a good resource.

Reply With Quote
  #4  
Old October 11th, 2012, 03:58 PM
Purity_Lake Purity_Lake is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2012
Posts: 33 Purity_Lake User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 8 h 25 m 17 sec
Reputation Power: 2
Quote:
Originally Posted by FrogBox
I'm aware that it is already basically a calculator, all I did was ask what the person would like to do and with shich numbers. Also, yes, I know they are modules, but knowing that doesnt not help me program in it. I've been trying to learn for a while but its hard to find a good resource.


ok so basically you want to learn all these modules, they all require a high level of knowledge of python, i'm not saying you are crap at python but make sure you know alot about the already builtin functions of python the modules python comes loaded with as it is the very building blocks of learning to use wxPython and Pygame, stick with just plain old python for the moment, also just to let you know there is a preloaded GUI module called Tkinter try it out and see if you like it

as in regards to resources, the source of where you got the module is generally the best place to look for documentation and tutorials or showcases of functions. there is usually dedicated forums for the likes of wxPython and Pygame so when you move on to those, ask the community they can be very helpful

Reply With Quote
  #5  
Old October 11th, 2012, 08:16 PM
FrogBox FrogBox is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2012
Posts: 3 FrogBox User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 51 m 57 sec
Reputation Power: 0
Quote:
Originally Posted by Purity_Lake
ok so basically you want to learn all these modules, they all require a high level of knowledge of python, i'm not saying you are crap at python but make sure you know alot about the already builtin functions of python the modules python comes loaded with as it is the very building blocks of learning to use wxPython and Pygame, stick with just plain old python for the moment, also just to let you know there is a preloaded GUI module called Tkinter try it out and see if you like it

as in regards to resources, the source of where you got the module is generally the best place to look for documentation and tutorials or showcases of functions. there is usually dedicated forums for the likes of wxPython and Pygame so when you move on to those, ask the community they can be very helpful


Hey, Cool, didn't know about TkInter, Ima go take a look at it.

Reply With Quote
  #6  
Old October 13th, 2012, 08:22 PM
myrmounet myrmounet is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2012
Posts: 6 myrmounet User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 52 m 16 sec
Reputation Power: 0
Newbie of Python, whut a lovely game !

i mean, i wanna learn python's language as well as you !
so, let's have a cup of tea; it's a word_count_dict function that read a file, txt one, and that count any words in. (thinking about a classical huh? i wanna learn ! lol)
my code is not working, it have been some weeks i grab on the net, seeking a solution, but no answers !
please help me if you want to, ill check my email everyday !
thanks to you, here is my code !
def word_count_dict(filename):
word_count = {}
compte = 0
input_file = open(filename, 'r')
data = input_file
data = data.replace(' ', '')
data = data.replace('\n', '')
for word in data :


if word in data.keys():
word_count[word]=compte +1
else :
word_count[word]= 1
return word_count

if __name__ == '__main__':
numbers_of_teas(countxt)
main()


not very cool as my code, please answer me huge lessons of code, so i shut up and get the lesson

Reply With Quote
  #7  
Old October 13th, 2012, 09:25 PM
b49P23TIvg's Avatar
b49P23TIvg b49P23TIvg is offline
Contributing User
Dev Shed Loyal (3000 - 3499 posts)
 
Join Date: Aug 2011
Posts: 3,371 b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level)b49P23TIvg User rank is Major (30000 - 40000 Reputation Level) 
Time spent in forums: 1 Month 2 Weeks 3 Days 11 h 35 m 33 sec
Reputation Power: 383
Study python rather than patching together snippets of code you find into an incomprehensible glob.
Code:
'Do we agree this sentence contains eight words?'

# what language are you trying to count?

def word_count_dict(filename):
    word_count = {}
    compte = 0
    input_file = open(filename, 'r')

    ################ here you'll likely want to read the file ################
    data = input_file
    
    ################ rather than clumping words ################
    #1) replace new line with space character
    data = data.replace('\n', ' ')
    #2) replace all regular expression of punctuation and white space repeated with a single space.
    #3) break the data into words with string.split method.
    data = data.replace(' ', '')
    for word in data:
        if word in data.keys():

            ################ you'll need to increment word_count[word]  The compte variable is of no use that I can comprehend ################
            word_count[word]=compte +1

        else:
            word_count[word]= 1
    return word_count

if __name__ == '__main__':

    ################ there isn't a function named numbers_of_teas ################
    numbers_of_teas(countxt)

    ################ there isn't a function named main ################
    main()

Reply With Quote
  #8  
Old October 14th, 2012, 10:45 PM
Xenith Xenith is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2012
Posts: 12 Xenith User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 3 h 47 m 52 sec
Reputation Power: 0
You can download free ebooks for the python language all over the internet. You can also check your local library, I'm sure they have more than a few.

Reply With Quote
  #9  
Old October 15th, 2012, 10:30 AM
myrmounet myrmounet is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2012
Posts: 6 myrmounet User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 52 m 16 sec
Reputation Power: 0
Newbie of Python, whut a lovely game ! Again

cup_of_teas were a relevant code change.
excuse me for my poor english, huh, im francophile.
and i have bought a python's book already !
Practical Programming An introduction to Computer Science using Python.
excuse me for the ad, i didnt notice this site forbid ads.
and about the code, i tell you, it's from the google class python, i can get some ebooks, but i have two or more, and i wanna go to the google class, the videos on youtube i have seen are very good, and i'm at dict and file.
you can see it as i show it :uh im a new user i cant ad the google class as URL !
can you help me on my code? i wanna dict one txt file given by google class teacher, and the text is in english, about alice in .. i dunno where in english, in french lol : alice aux pays des merveilles !
thanks and see ya
Signed a Python 's newbie

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPython Programming > Learning Python/PyGame/WXPython/ect.

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap