Re: [Tutor] starting to learn

2012-07-16 Thread Jugurtha Hadjar
On 07/12/2012 12:46 AM, blindmaildrop wrote: Hello! I am just starting to learn python, having signed up for a class on it in University. The last time I programmed anything was in the long long long ago of BASIC and (well since I spent time doing other things) I missed the development boat.

Re: [Tutor] How to get two user inputs in same prompt seperated by a special character?

2012-07-16 Thread Alan Gauld
On 14/07/12 04:46, Santosh Kumar wrote: height_in_feet = input(How much feet are you long: ) remaining_inches = input(How much inches remained? ) Here I want something like: Enter you height in format like 5' 10 Mario has given a partial answer for this specific case although he missed

Re: [Tutor] converting EBCIDIC to ASCII

2012-07-16 Thread Flynn, Stephen (L P - IT)
I am trying to convert an EBCIDIC file to ASCII, when the records are fixed length I can convert it fine, I have some files that are coming in as variable length records, is there a way to convert the file in Python? I tried using no length but then it just reads in to a fixed buffer size and I

Re: [Tutor] converting EBCIDIC to ASCII

2012-07-16 Thread Flynn, Stephen (L P - IT)
-Original Message- From: tutor-bounces+steve.flynn=capita.co...@python.org [mailto:tutor- bounces+steve.flynn=capita.co...@python.org] On Behalf Of Steven D'Aprano Sent: Saturday, July 14, 2012 2:42 AM To: tutor@python.org Subject: Re: [Tutor] converting EBCIDIC to ASCII Prinn,

[Tutor] passing global variable as argument.

2012-07-16 Thread Bala subramanian
Friends, I want to define a function that can populate an array by taking its name (which is defined globally). I defined two empty arrays as follows and a function that can populate the array. REF_F1=np.array([]) REF_F2=np.array([]) # populating the given array def ref(ln,REF_F1): global

Re: [Tutor] passing global variable as argument.

2012-07-16 Thread Dave Angel
On 07/16/2012 07:00 AM, Bala subramanian wrote: Friends, I want to define a function that can populate an array by taking its name (which is defined globally). I defined two empty arrays as follows and a function that can populate the array. REF_F1=np.array([]) REF_F2=np.array([]) #

Re: [Tutor] passing global variable as argument.

2012-07-16 Thread Wayne Werner
On Mon, 16 Jul 2012, Bala subramanian wrote: Friends, I want to define a function that can populate an array by taking its name (which is defined globally). Are you sure this is what you really want to do? I've noticed that many times that I want to do something, but only because I don't

[Tutor] newbie Questions

2012-07-16 Thread Matthew Ngaha
Hi all. I'm new to Python and Programming in general. I've started out with Python for beginners, and so far so good. My friend who i might add, is not a programmer but has had experience in the world of programming (i dont know how much but he claims a lot), has told me to forget about Python and

Re: [Tutor] newbie Questions

2012-07-16 Thread Walter Prins
Hi Matthew, On 16 July 2012 13:09, Matthew Ngaha chigga...@gmail.com wrote: Hi all. I'm new to Python and Programming in general. I've started out with Python for beginners, and so far so good. My friend who i might add, is not a programmer but has had experience in the world of programming (i

Re: [Tutor] newbie Questions

2012-07-16 Thread Walter Prins
Hi again Matthew, I forgot to include the following link which I originally thought to include, which is one guy's set of (IMHO very cogent) criticisms against PHP as programming language: http://is.gd/z1POXC Hopefully it gives you something else to think about regarding the PHP vs Python

Re: [Tutor] newbie Questions

2012-07-16 Thread Monte Milanuk
Probably the single biggest 'problem' with Python for web development, in my opinion, is that while a lot of web hosts have all sorts of PHP templates or frameworks installed and ready for easy deployment... Python options seem to be a bit sparser. Individual hosts may vary, but thats the overall

Re: [Tutor] newbie Questions

2012-07-16 Thread Wayne Werner
On Mon, 16 Jul 2012, Walter Prins wrote: Hi again Matthew, I forgot to include the following link which I originally thought to include, which is one guy's set of (IMHO very cogent) criticisms against PHP as programming language: http://is.gd/z1POXC Hopefully it gives you something else to

Re: [Tutor] newbie Questions

2012-07-16 Thread Joel Goldstick
On Mon, Jul 16, 2012 at 9:54 AM, Wayne Werner wa...@waynewerner.com wrote: On Mon, 16 Jul 2012, Walter Prins wrote: Hi again Matthew, I forgot to include the following link which I originally thought to include, which is one guy's set of (IMHO very cogent) criticisms against PHP as

Re: [Tutor] newbie Questions

2012-07-16 Thread Steven D'Aprano
Matthew Ngaha wrote: Hi all. I'm new to Python and Programming in general. I've started out with Python for beginners, and so far so good. My friend who i might add, is not a programmer but has had experience in the world of programming (i dont know how much but he claims a lot), has told me to

[Tutor] Extracting columns from many files to different files

2012-07-16 Thread susana moreno colomer
Hi! I have a folder, with the following text files with columns: bb_ 1 bb_2 ww_1 ww_2 ff_1 ff_2 What I want to do is: Extract columns 5,6, 8 from files bb_ Extract columns 3,4 from files ww_ Get 5 files, corresponding to different columns: Files (excel files): 'ro' with colums number 5,

Re: [Tutor] passing global variable as argument.

2012-07-16 Thread Steven D'Aprano
Bala subramanian wrote: Friends, I want to define a function that can populate an array by taking its name (which is defined globally). I defined two empty arrays as follows and a function that can populate the array. In general it is tricky to resize and populate numpy arrays in place. It is

Re: [Tutor] newbie Questions

2012-07-16 Thread Alexandre Zani
On Mon, Jul 16, 2012 at 5:09 AM, Matthew Ngaha chigga...@gmail.com wrote: Hi all. I'm new to Python and Programming in general. I've started out with Python for beginners, and so far so good. My friend who i might add, is not a programmer but has had experience in the world of programming (i

Re: [Tutor] passing global variable as argument.

2012-07-16 Thread Bala subramanian
Thank you wayne and steven. You suggestion to create a fresh array within the function and assigning it to variable worked fine and the result was exactly what i was looking for. In future i remember not to use global variables as fn. parameters. thanks once again for detailed explanation, bala

Re: [Tutor] Extracting columns from many files to different files

2012-07-16 Thread taserian
On Mon, Jul 16, 2012 at 10:58 AM, susana moreno colomer susana...@hotmail.com wrote: Hi! I have a folder, with the following text files with columns: bb_ 1 bb_2 ww_1 ww_2 ff_1 ff_2 What I want to do is: - Extract columns 5,6, 8 from files bb_ - Extract columns 3,4 from files

Re: [Tutor] Extracting columns from many files to different files

2012-07-16 Thread Joel Goldstick
On Mon, Jul 16, 2012 at 12:11 PM, taserian taser...@gmail.com wrote: On Mon, Jul 16, 2012 at 10:58 AM, susana moreno colomer susana...@hotmail.com wrote: Hi! I have a folder, with the following text files with columns: bb_ 1 bb_2 ww_1 ww_2 ff_1 ff_2 What I want to do is: Extract

Re: [Tutor] Extracting columns from many files to different files

2012-07-16 Thread susana moreno colomer
They are separated by tabs Date: Mon, 16 Jul 2012 12:16:22 -0400 Subject: Re: [Tutor] Extracting columns from many files to different files From: joel.goldst...@gmail.com To: taser...@gmail.com CC: susana...@hotmail.com; tutor@python.org On Mon, Jul 16, 2012 at 12:11 PM, taserian

Re: [Tutor] Extracting columns from many files to different files

2012-07-16 Thread Joel Goldstick
On Mon, Jul 16, 2012 at 12:24 PM, susana moreno colomer susana...@hotmail.com wrote: They are separated by tabs Date: Mon, 16 Jul 2012 12:16:22 -0400 Subject: Re: [Tutor] Extracting columns from many files to different files From: joel.goldst...@gmail.com To: taser...@gmail.com CC:

Re: [Tutor] newbie Questions

2012-07-16 Thread Matthew Ngaha
Thanks guys, i didnt think i would get so many kind and helpful responses. I am so grateful:x. I have read each and every reply and i am now very confident in the direction i need to take. Everything is a lot clearer now. Even though i'm new to programming, i am very intrigued by it and want to

Re: [Tutor] Extracting columns from many files to different files

2012-07-16 Thread Dave Angel
On 07/16/2012 12:58 PM, Joel Goldstick wrote: On Mon, Jul 16, 2012 at 12:24 PM, susana moreno colomer susana...@hotmail.com wrote: They are separated by tabs You're top-posting again. The history of all these other messages is thoroughly obfuscated if you don't follow the convention of adding

Re: [Tutor] Extracting columns from many files to different files

2012-07-16 Thread Walter Prins
Hi On 16 July 2012 15:58, susana moreno colomer susana...@hotmail.com wrote: Hi! I have a folder, with the following text files with columns: If I may ask, how does this question relate to your previous similar question(s)? What do you want to do with these 5 files once you have them?

Re: [Tutor] newbie Questions

2012-07-16 Thread Jordan
I would just like to add that I am a web developer and I left PHP for Python. I left PHP because it was not as powerful server side (Cron Jobs and Such) and I wanted to possibly create desktop applications, more recently Android Apps via SL4A and IPhone Apps via pyjamas. PHP is a limited language

Re: [Tutor] newbie Questions

2012-07-16 Thread Vignesh Sathiamoorthy
Check out http://www.udacity.com/ Enroll in few courses - to begin with, check http://www.udacity.com/view#Course/cs101/CourseRev/apr2012/Unit/671001/Nugget/675002 On Mon, Jul 16, 2012 at 5:09 AM, Matthew Ngaha chigga...@gmail.com wrote: Hi all. I'm new to Python and Programming in

Re: [Tutor] starting to learn

2012-07-16 Thread Vignesh Sathiamoorthy
Have you explored ( http://ocw.mit.edu/courses/electrical-engineering-and-computer-science/6-189-a-gentle-introduction-to-programming-using-python-january-iap-2011/ ) check out their assignments, sample programs, lecture notes .. Also start reading/executing examples/codes from