[Tutor] Scrolling through output in shell

2008-11-16 Thread Mike Hoy
gram? I noticed that on the man pages that you can do that although I'm sure it's not written in python. Do I need to find a new language to write this in? Maybe use a different language for the output and still use python? Any help appreciated. -- Mike H

Re: [Tutor] Scrolling through output in shell

2008-11-17 Thread Mike Hoy
Ok thanks Alan for looking into it. I'll give it a try. On Mon, Nov 17, 2008 at 12:27 PM, ALAN GAULD <[EMAIL PROTECTED]> wrote: > Forwarding to the group. > Please use Reply All when responding. > > > - Original Message > From: Mike Hoy <[EMAIL PROT

Re: [Tutor] Scrolling through output in shell

2008-11-19 Thread Mike Hoy
os.system("cat textfile | less") did the trick, thanks everyone. On Wed, Nov 19, 2008 at 2:34 PM, Lie Ryan <[EMAIL PROTECTED]> wrote: > On Mon, 17 Nov 2008 09:20:55 -0500, Shawn Milochik wrote: > >> On Sun, Nov 16, 2008 at 1:21 PM, Mike Hoy <[EMAIL PROTECTED]&

[Tutor] Open Source database software

2008-11-24 Thread Mike Meisner
ser data input, queries, reports, etc. 4. Smart enough to easily read and convert an Access (.mdb) database file. 5. And, everything either in Python or with APIs that Python can easily use. Has anyone used products that would meet my needs?

[Tutor] Jython question

2008-12-05 Thread Mike Hoy
ughts? -- Mike Hoy ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor

[Tutor] multiple if and or statement

2011-03-14 Thread Mike Franon
HI, I had a question, when running this small snippet of test code: a = ['test1', 'flag', 'monday'] for i in a: if i == 'test1' or 'test2': print 'true' It always prints true $ ./testing.py true true true I know I am missing something, but in reality it should only print true

Re: [Tutor] multiple if and or statement

2011-03-14 Thread Mike Franon
each item in the list one at a time like a loop I was thinking, so the first time it would test for 'test1', and the second time it would test for 'flag', did not realize it would test the entire list all at once. On Mon, Mar 14, 2011 at 4:00 PM, Marc Tompkins wrote: >

[Tutor] Running python on windows

2011-04-11 Thread Mike Silverson
Hi, I need to know if there is any way to run a python file without Python installed on the target computer. I am trying to send a program to a friend using windows and he does not have python installed, and does not want to take the time to install it. Is there any way to send him the file (or a

[Tutor] Accessing Specific Dictionary items

2011-08-01 Thread Mike Nickey
Hi all, I'm trying to access and use specific items within a dictionary that is returned but am having issues in doing so. [{'city': 'Sunnyvale', 'region_name': 'CA', 'area_code': 408, 'metro_code': 'Santa Clara, CA', 'country_name': 'United States'}] How can I populate a list of many different r

Re: [Tutor] Accessing Specific Dictionary items

2011-08-01 Thread Mike Nickey
append and populate a list but I don't know how to pull an item by key value from the dictionary returns. I hope this helps clear some confusion and thanks in advance. On Mon, Aug 1, 2011 at 15:14, ian douglas wrote: > On 08/01/2011 03:05 PM, Mike Nickey wrote: >> >> Hi all, >

Re: [Tutor] Accessing Specific Dictionary items

2011-08-01 Thread Mike Nickey
to a variable > > Or you can append to a list directly. > > l = [] > > for d in yourdict: >     l.append(d['city']) > > > Sent from my Verizon Wireless BlackBerry > > -Original Message- > From: Mike Nickey > Sender: tutor-bounces+eire1130=gmail.

[Tutor] declaring a blank interger

2011-10-05 Thread Mike Nickey
: UserName = raw_input("Enter your name: ") return UserName def getUserNumber(x): x = input("Enter a number:") #This will be the users unique ID number return x getUserName() getUserNumber(x) print UserName, x Be

[Tutor] Finding if a passed variable is within to set parameters

2011-10-10 Thread Mike Nickey
t;= 8) and (UserSkillLvl >=1)): print "thank you" temp = 1 break elif (UserSkillLvl >8) or (UserSkillLvl < 1): while temp == 0: UserSkillLvl = raw_input("Please re-enter your skill level: ")

[Tutor] Creating Android Apps w/ Python

2011-11-02 Thread Mike Nickey
I'm currently taking a class on Android Development. The instructor says that the code needed has to be done through Java. Isn't there any way to create these same apps with Python? I read on the Android Dev site that MonkeyRunner can assist but does anyone else have any experience on how well this

[Tutor] Moving from snippits to large projects?

2012-01-09 Thread Mike G
How does one go from small to medium, to large, as a coder? You might look into contributing to an existing project. There is a new project, MediaLocker, a Python / wxPython app recently underway, started from a blog post. I believe they are looking for input, including contributing - have a lo

[Tutor] Issue with Python 2.7.2 - beginner needing help

2012-01-10 Thread Mike G
Hi Tonyelle Your code doesn't work as expected due to your 2nd edition book uses Python 3x, see page xi, 'Changes in this edition'. This would work for your version of Python... room = 503 print 'I am staying in room number', room If you're new, Python 2.7.2 is (IMO) a better choice, many more

[Tutor] Extremely simple question

2012-01-11 Thread Mike G
Hi Chris I'm new to programming and Python myself so I would listen to the previous guys first, and I'll repeat a bit of what has already been mentioned... Make sure you define 'x'. Is name really an 'int', or is it possibly a 'str'? Fix any indentation issues. Is there anything you can do with

[Tutor] Are there other ways of solving this exercise?

2012-01-12 Thread Mike G
...Exercise 16, extra credit 3...Code from the book...like the author mentioned The book and author, do they have a name...? Is this an exercise in refactoring? ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http

[Tutor] GameTracker help

2012-02-25 Thread Mike Nickey
Hey all, I'm trying to wok on a game tracker for my friends. What I have here partly works but there are areas that I want to change and some areas that are just not working for me. The areas that I am having difficulty with are the def pointsNeeded and oppPointsNeeded. What is strange to me is t

Re: [Tutor] GameTracker help

2012-02-25 Thread Mike Nickey
it's not redundant code? On Sat, Feb 25, 2012 at 02:07, Mike Nickey wrote: > Hey all, > > I'm trying to wok on a game tracker for my friends. What I have here > partly works but there are areas that I want to change and some areas > that are just not working for me.

[Tutor] generators

2012-04-03 Thread mike jackson
I am trying understand python and have done fairly well, So for it has been easy to learn and is concise.  However I seem to not quite understand the use of a generator over a function(I am familiar with functions [other languages and math]).  To me (excepting obvious syntax differences) a gener

[Tutor] Finding palindromes in a list

2012-06-08 Thread Mike Nickey
I'm trying to write a bit of code that will run through a text file and find the item or word string that is the same forward as it is when it is revered...a palindrome. I'm having a bit of issue looping through the wordList[] that I have created. If you have any comments or suggestions I'd really

Re: [Tutor] Finding palindromes in a list

2012-06-08 Thread Mike Nickey
print "\nPrinting palindromes" print palindromes[:] print "\nDone!!!" On Fri, Jun 8, 2012 at 6:38 PM, Dave Angel wrote: > On 06/08/2012 09:01 PM, Marc Tompkins wrote: >> On Fri, Jun 8, 2012 at 5:10 PM, Mike Nickey wrote: >> >>> def compareElements(wor

[Tutor] getpass

2012-06-15 Thread Mike Nickey
Hey all, I'm working on a bit of code here and I'm having an issue with getpass. In the documentation, it says it hides the text entered "Prompt the user for a password without echoing." -- http://www.python.org/doc//current/library/getpass.html However when I run it in Eclipse, the password is

[Tutor] Sorting tuples

2012-06-20 Thread Mike Nickey
Hey all, I'm working through the google classes to increase my python understanding and I'm stuck on sorting tuples. What is being asked is to sort tuples based on the second element of the tuple in ascending order. Given a list of non-empty tuples, return a list sorted in increasing order by the

Re: [Tutor] Sorting tuples

2012-06-20 Thread Mike Nickey
While i'm still not sure what lamda is or represents, I've found a solution. Thank you all for your assistance, past, present and future. :) This seems to work: def sort_last(tuples): return sorted(tuples, key=myDef) def myDef(s): return s[-1] On Wed, Jun 20, 2012 at 4:0

Re: [Tutor] Tutor Digest, Vol 100, Issue 58

2012-06-25 Thread Mike Nickey
>> The problem with this code is that it only gets the first word beginning >> with x and the others remaisn on the original list, sorted at the end. I've >> tested on terminal many parts of the code and it whas fine, but when I run >> it complete, it does not work. >> >> Following is the solution

[Tutor] Creating a dictionary on user filter

2012-07-19 Thread Mike Nickey
Hi All, I have a few lists that I'm trying to put into a dictionary based on which list the user wants to use as a filter. If the user selects 1 the the dictionary would be created using the first list as the keys and the secondary items as the values. If the user selects 2, the dictionary would b

[Tutor] Sigh first real python task

2012-09-12 Thread Mike S
print >>sys.stderr, "Child was terminated by signal", -ret else: os.unlink(path+fileName) except OSError, e: print >>sys.stderr, "Execution failed:", e Any help would be appreciated. -- Mike of Many Stories, Ideas, and Ra

Re: [Tutor] Sigh first real python task

2012-09-12 Thread Mike S
Sorry, hit send a bit too fast there: here is the output: session setup failed: NT_STATUS_LOGON_FAILURE /bin/sh: put: command not found On Wed, Sep 12, 2012 at 8:14 PM, Steven D'Aprano wrote: > On 13/09/12 13:06, Mike S wrote: > > Now, I'm having to change the remote hos

[Tutor] name conventions

2012-10-22 Thread Mike McTernan
Hi there, I am doing some online tutorials and have found two approaches to naming things: this_is_a_name and thisIsAName. Which one is the best practice for Python? I am a totally newbie to programming and want to make sure I start with the most common approach. Thanks, mike

Re: [Tutor] Help - International School in Spain

2015-11-17 Thread Mike Straw
Caroline, The parentheses change the interpretation for the print statement. If you put it without the parentheses, it will work fine. print "Mashed ",veg," on the ceiling." Also, another note: the spaces at end of the first string and the start of the third string aren't necessary. When you use

[Tutor] Cluster analysis script error

2016-10-11 Thread Mike Armson
s to be working, as there were originally errors here, but I fixed them. Thanks very much for your help! Mike -- *Mike Armson, PhD Candidate* University of Toronto, Department of Psychology Levine Lab, Rotman Research Institute, Baycrest *p:* (416) 785-2500 x.2826 *e: marm...@research.baycrest

Re: [Tutor] Clearing Python text

2012-12-14 Thread Mike G
then hit enter - file run or screen cleared, as well saves time retyping. Sorry if I missed it but this works for me because I too prefer to print to a cleared screen, don't know why, just do. Mike :) ___ Tutor maillist - Tutor@python.org To uns

Re: [Tutor] help

2012-12-30 Thread Mike G
may be how you're running the program. I would use a py file and run it using cmd - holler if you need help, you may if the path to Python isn't good to go. Mike ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor

[Tutor] help

2013-01-08 Thread Mike G
may be how you're running the program. I would use a py file and run it using cmd - holler if you need help, you may if the path to Python isn't good to go. Mike ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor

[Tutor] Python version 2.7 or 3.0

2013-03-12 Thread Mike Nickey
Hey all, I'm used to python 2.7 but I'm seeing and hearing a lot about 3.0 and wanted to ask a few questions. I'm seeing on StackOverflow that 2.7 is the standard for those that have libraries that haven't been ported to 3.1.2 yet. Does this mean that 2.7 is dead or dying? Is this just a well mana

[Tutor] Splitting on punctuation

2013-06-08 Thread Mike Nickey
Hey guys, I'm working on a web-project simply to bruh up on skills and build new ones. One of the tasks is to split on punctuation passed yet I'm having a bit more trouble then I expected. Give the input of "which isn't that surprising I guess.",",'.") where the first part passed is the string an

Re: [Tutor] Tutor Digest, Vol 112, Issue 29

2013-06-09 Thread Mike Nickey
on punctuation (Alan Gauld) > > > -- > > Message: 1 > Date: Sun, 09 Jun 2013 06:48:13 +0100 > From: Alan Gauld > To: tutor@python.org > Subject: Re: [Tutor] Splitting on punctuation > Message-ID:

[Tutor] why do i keep getting syntax errors in python when this runs

2013-09-06 Thread mike johnson
can you please help me figure out why this isnt working thanks # convert.py # this program is used to convert Celsius temps to Fahrenheit # By: James Michael Johnson Def main (): Celsius = float (input ("What is the Celsius temperature? ")) Fahrenheit = 9.0 / 5.0 * Celsius + 32 Print ("The tempera

[Tutor] Returns an iterator of tuples

2013-11-27 Thread Mike Sila
I know what return, iteration and tuples are.  Can anyone please tell me what an iterator of tuples is? Thanks On Wednesday, November 27, 2013 11:00 AM, "tutor-requ...@python.org" wrote: Welcome to the Tutor@python.org mailing list! This list is for folks who want to ask (and/or answer) qu

[Tutor] Off topic - Ruby similar list?

2014-07-09 Thread Mike Nickey
Just curious if there's a similar list like this one for Ruby-ists. Anyone know of one or two? TIA -- ~MEN ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/mailman/listinfo/tutor

[Tutor] New at Python

2014-10-05 Thread Mike Spaulding
Given that n refers to a positive int use a while loop to compute the sum of the cubes of the first n counting numbers, and associate this value with total . Use no variables other than n , k , and total . Hi, I am r

[Tutor] SQLAlchemy

2015-01-26 Thread Mike Nickey
Hey folks, I'm working my way through Thinkful with python and I'm trying to get a setup working. Part of this setup is using SQLAlchemy. While I understand this is a python tutor list, would it be OK to ask questions like 'how do I change my SQLAlchemy URL to include a user name' here? -- ~MEN

Re: [Tutor] Coming from R, what's a good IDE editor? I've tried PyCharm and Spyder

2017-06-03 Thread Mike C
Hi Ben, I have not used Vim or Emacs for a very long time. I am spoiled by the friendly interface of RStudio. There is a high demand for Python in the industry, but there has not been a good IDE. I find that strange. _ From: Ben Finney mailto:ben+pyt...@benfinney.i

Re: [Tutor] Coming from R, what's a good IDE editor? I've tried PyCharm and Spyder

2017-06-04 Thread Mike C
Hi Ben, Yes, I read your suggestion. I should have added the following in my earlier message. Jupyter runs in a web browser like Chrome, and you feed it in line by line, so if I want to run a project with a hundred lines, it may take a few. Anyways, Jupyter is the consensus, and I am trying it

Re: [Tutor] Installing Python3.6.1 on Ubuntu 16.04.2

2017-07-03 Thread Mike Lisanke
> >Tutor maillist - Tutor@python.org > >To unsubscribe or change subscription options: > >https://mail.python.org/mailman/listinfo/tutor > > -- > Sent from my Android device with K-9 Mail. Please excuse my brevity. > ___ > Tutor maillist - Tutor@python.org > To un

Re: [Tutor] Help with python 2.7

2017-10-30 Thread Mike Miller
said that for someone with even average skill and ability, the MS course is actually great and easy to follow on. Good luck, and welcome. Mike On Mon, Oct 30, 2017, 7:24 PM Alchemy wrote: > Hello, > > I am in the midst of a career change from renovations to computers. > I’m use

Re: [Tutor] request.post in If condition

2017-10-31 Thread Mike Miller
What do you mean when you say it is not hitting? Is there a specific error, or are you saying it simply isn't posting to your site? Mike On Mon, Oct 30, 2017, 8:21 AM sourav voip wrote: > Hi All, > > I'm trying to hit request.post with condition using if-else as below... >

[Tutor] Visual Studio issue when pip installing mysql-python

2017-11-08 Thread Mike Nickey
Hi all, I understand that this might be out of the scope of this list but I am hopeful that someone has some insight on it so I can move forward with this project. This is a hail mary attempt to get this resolved. The issue that I am seeing is that I have a script that works well locally. I am tr

Re: [Tutor] In matplotlib, why are there axes classes vs. axes API? Why not list them under one documentation?

2018-06-16 Thread Mike C
I can only compare to the R language I've used. If there is an issue, say a function freezes at startup, one user brings it up to the list, when the respective maintainer sees the bug, it is usually addressed on the next release. In terms of funding. Isn't Python heavily used in industry, so, fi

[Tutor] Any 'graphical' ways of learning Python

2018-12-06 Thread Mike Barnett
use windows instead. If you want to learn more about the overall architecture, this recent post will help: https://www.reddit.com/r/Python/comments/a1mj0p/pysimplegui_under_the_hood/ @mike<mailto:mike_barn...@hotmail.com> ___ Tutor maillist -

Re: [Tutor] Any 'graphical' ways of learning Python

2018-12-06 Thread Mike Barnett
=PLl8dD0doyrvHMoJGTdMtgLuHymaqJVjzt -mike ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/mailman/listinfo/tutor

Re: [Tutor] graphics library for teaching Python

2018-12-21 Thread Mike Barnett
47380967-b6012180-d6cc-11e8-946d-a646921fb8d0.gif These are all tkinter based examples. While PySimpleGUI does have a Qt port, it's not as complete when it comes to these graphics primitives and integration with Matplotlib. -mike ___ Tutor

Re: [Tutor] graphics library for teaching Python

2018-12-21 Thread Mike Barnett
for the background of a canvas, but of the entire window. For that you’ll need to use PySimpleGUIQt. Anyway, it’s worth a look to see if it fits some of your needs. @mike<mailto:mike_barn...@hotmail.com> From: Michael Mossey Sent: Friday, December 21, 2018 1:40 PM To: Mike Barnett Cc:

Re: [Tutor] decomposing a problem

2018-12-28 Thread Mike Mossey
read the results in their expression and their understanding. I think it’s important both to have something you are aiming for (a sense of what level of brevity you’d like to achieve) and a feedback mechanism that helps you to know if you are succeeding. Ta

Re: [Tutor] Recommended Resurce or strategy for beginning students

2019-01-22 Thread Mike Barnett
arm in approaching the problem from a different direction. It could be wildly successful. Or... not... The worst that can happen is you screw up a classroom full of future programmers, creating a warped vision that GUIs can be fun and easy. @mike -Original Message- From: Mat

Re: [Tutor] Recommended Resurce or strategy for beginning students

2019-02-04 Thread Mike Barnett
Be cautious when using IDLE with tkinter based programs (PySimpleGUI falls into this category). IDLE is written using tkinter. You can sometimes end up with tkinter complaining about the mainloop running in multiple locations or freeing resources in the wrong thread. @mike<mailto:mike_b

Re: [Tutor] Recommended Resurce or strategy for beginning students

2019-02-21 Thread Mike Barnett
even needing Python installed on their computer. It’s Remi<https://github.com/dddomodossola/remi>, by the way, that is the magic behind PySimpleGUIWeb. @mike<mailto:mike_barn...@hotmail.com> From: Matthew Polack Sent: Wednesday, February 20, 2019 10:35 PM To: David ; Mike Bar

Re: [Tutor] What does 'Bind Return Key' do?

2019-04-29 Thread Mike Barnett
om and left to right. -- When questions like this arise on PySimpleGUI, I recommend pulling up the docs and pressing Control-F to do a search. @mike -Original Message- From: Matthew Polack Sent: Sunday, April 28, 2019 4:49 AM To: tutor@python.org S

Re: [Tutor] Interactive editing of variables.

2019-06-01 Thread Mike Barnett
impleGUI / tkinter: https://repl.it/@PySimpleGUI/Reddit-Change-variables-GUI My estimate wasn't too far off 18 lines of code in total. Is this the kind of modification of variables you where talking about? @mike -Original Message- From: Sean Murphy Sent: Saturday, June 1, 2019

Re: [Tutor] Interactive editing of variables.

2019-06-01 Thread Mike Barnett
e's the large debug window that allows you to do more including running the built-in REPL. There is also a version being built into the PySimpleGUI library itself so you do not have to do any imports, etc. All PySimpleGUI will have this watch/debug capability in it. @mike -Original

Re: [Tutor] Multiprocessing with many input input parameters

2019-07-11 Thread Mike Barnett
If you're passing parameters as a list, then you need a "," at the end of the items. Otherwise if you have something like a string as the only item, the list will be the string. list_with_one_item = ['item one',] @mike -Original Message- From: Shall, Sydne

Re: [Tutor] Multiprocessing with many input input parameters

2019-07-13 Thread Mike Barnett
Right, I meant tuple, not list. a = ('A string') b = ('A List Member',) print(a[0]) print(b[0]) The output for this is: A A List Member @mike -Original Message- From: Cameron Simpson Sent: Friday, July 12, 2019 7:59 PM To: Mike Barnett Cc: Shall, Sydne

Re: [Tutor] Simple RPN calculator

2004-12-05 Thread Mike in Seattle
Check out "How to think like a computer scientist", chap 20. He uses trees to evaluate expressions. http://www.ibiblio.org/obp/thinkCSpy/index.htm ___ Tutor maillist - [EMAIL PROTECTED] http://mail.python.org/mailman/listinfo/tutor

[Tutor] How to launch multiple processes from script?

2004-12-12 Thread Mike in Seattle
27;ve briefly played with spawn and forkpty with no success. Running WinXP right now. I am hoping that there is something as simple as this psuedo code: for i in range(1..10): run_with_console("client.py " + arg0[i] +" " +arg1[i]) My question is what is pytho

Re: [Tutor] pip install in a virtualenv *without* internet?

2015-08-19 Thread Mike C. Fletcher
Pi every time we do a rebuild of our virtualenvs (which we do for every testing build). HTH, Mike -- Mike C. Fletcher Designer, VR Plumber, Coder http://www.vrplumber.com http://blog.vrplumber.com ___

Re: [Tutor] pip install in a virtualenv *without* internet?

2015-08-19 Thread Mike C. Fletcher
On 15-08-19 05:27 AM, Alex Kleider wrote: On 2015-08-18 19:32, Mike C. Fletcher wrote: To install without going out to the internet, you can use these arguments: pip install --no-index --find-links=/path/to/download/directory For this to work, /path/to/download/directory would, I

<    1   2   3   4