On Thu, 9 Jan 2014 21:41:41 +1100, Steven D'Aprano
wrote:
I presume that your question is aimed at Keith.
Yes, Keith's emails have a HTML part and a text part. A half-decent
mail
client should be able to read the text part even if the HTML part
exists. But I believe you're reading this fro
On Thu, 9 Jan 2014 13:02:30 -0500, Keith Winston
wrote:
Well, hopefully this is plain text. It all looks the same to me, so
if
gmail switches back, it might go unnoticed for a while. Sorry for
the
incessant hassle.
That looks great, thanks.
--
DaveA
_
Keith Winston Wrote in message:
> I've got this line:
>
> for k in range(len(tcombo)):
> tcombo_ep.append(list(combinations(tcombo, k+1)))
>
> generating every possible length combination of tcombo. I then test
> them, and throw most of them away. I need to do this differently, it
> gets wa
Roelof Wobben Wrote in message:
That documentation says nothing about order. And the test cases
specifically contradict it.
so try
if set (b) <= set (a):
--
DaveA
Android NewsGroup Reader
http://www.piaohong.tk/newsgroup
___
Tutor ma
Keith Winston Wrote in message:
> I'm working through some of the Project Euler problems, and the
> following might spoil one of the problems, so perhaps you don't want
> to read further...
>
>
> The problem relates to finding all possible combinations of coins that
> equal a given total. I'm b
Alan Gauld Wrote in message:
> On 14/01/14 07:42, Christian Alexander wrote:
>
>> Why does the interactive prompt not recognize escape sequences in
>> strings? It only works correctly if I use the print function in python 3.
>>
>> >>> "Hello\nWorld"
>> "Hello\nWorld"
>
> That depends on how y
Steven D'Aprano Wrote in message:
> On Fri, Jan 17, 2014 at 08:35:04AM -0500, eryksun wrote:
>> On Fri, Jan 17, 2014 at 6:23 AM, Steven D'Aprano wrote:
>> > On Fri, Jan 17, 2014 at 09:58:06AM +, James Chapman wrote:
> [...]
>> >> import mockimport unittestimport pinger
>> >> class Test_Ping
SM Wrote in message:
> Sorry for not giving details on the OS and python version I am using: Ubuntu
> and Python3
On Sun, Jan 19, 2014 at 8:20 PM, Alan Gauld wrote:
On 19/01/14 23:36, SM wrote:
>> I read about os.popen in
>> http://docs.python.org/2/library/subprocess.html#subprocess.Popen
>
Adam Hurwitz Wrote in message:
>
Many times when a function doesn't work, and you can't figure out
why, it pays to factor the function, at least temporarily, and
test the different parts. This might be your best bet in this
case, especially when I tell you that you're very close.
I the
Leon S Wrote in message:
> _
(please post in plain text in this text mailing list. Html messes
up formatting and causes some newsreaders grief.)
..
Leon said:
Here is what I'm trying to do, accept a price of gas, but I want
to add the .009 to the price, so that people do n
myles broomes Wrote in message:
> ___
> Tutor maillist - Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>
I'm guessing you're attempting to post here in this text newsgroup
using h
"Michael L. Pierre" Wrote in message:
> ___
> Tutor maillist - Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>
Start by posting in text form, since this is a text group. You
appa
scurvy scott Wrote in message:
> ___
> Tutor maillist - Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>
Please post as text, not html.
Try putting a print at the top of the code.
Aubri Sandlin Wrote in message:
> I have installed Python. When I open IDLE I get this warning: >>> WARNING:
> The version of Tcl/Tk (8.5.9) in use may be unstable.
> Visit http://www.python.org/download/mac/tcltk/ for current information.
>
>
> I have downloaded and installed the latest ver
Dave Angel Wrote in message:
> Aubri Sandlin Wrote in message:
>> I have installed Python. When I open IDLE I get this warning: >>> WARNING:
>> The version of Tcl/Tk (8.5.9) in use may be unstable.
>> Visit http://www.python.org/download/mac/tcltk/ for current
Denis Heidtmann Wrote in message:
>
>
What is going on? Â I am more confused than I was a week ago.
Simple. spir has copy/paste editing errors.
--
DaveA
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
https
Steven D'Aprano Wrote in message:
>
> Sorry Dave, your tools are letting you down again. Michael did in fact
> post with plain text. His original email included both a text/plain part
> and a text/html part.
>
> Now I'm no friend of posting in HTML, I think it&
Ian D Wrote in message:
> ___
> Tutor maillist - Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>
1) you forgot to escape the backslashes in your module path.
Either use forward sl
Kipton Moravec Wrote in message:
> I am new to Python, and I do not know how to traverse lists like I
> traverse arrays in C. This is my first program other than "Hello World".
> I have a Raspberry Pi and they say Python is the language of choice for
> that little machine. So I am going to try to
josh Malone Wrote in message:
> ___
> Tutor maillist - Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>
First thing is to figure your goal. "Model" might mean anything
from "figur
Ian D Wrote in message:
> ___
> Tutor maillist - Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>
When making an amendment to a post, please reply to that post;
don't start a new
Danny Yoo Wrote in message:
> (Sorry if you get this message twice: I think I accidently mis-sent
> the message to the wrong address, so to make sure, I'm sending to what
> I think is the right address this time.)
>
> ---
>
> Hi Premanshu,
[deleting useful advice]
Welcome to the list.
When
Ian D Wrote in message:
>
> import sys
> sys.path.append("d:\modules")
Â
> I have tried it with append("d:\\modules") append("d:/\modules")
Â
The first form is not reasonable, you'd need to double the
backslash. But your second try should have worked. Here's what I
would use:
"d:/modules"
spir Wrote in message:
>
> I have no idea of the pattern or structure of email headers. Would you post
> some
> example of 'msg_header_content[0][1]'?
>
> In the meantine, try to suppress \r from the regex formats. (Shouldn't be
> here,
> because when reading strings from files, python con
Ian D Wrote in message:
> __ Ok I seem to be having some success with it at the moment after moving
> the location of the module.
That might be because the letter following the backslash is not
currently a valid escape code. You really shouldn't leave half
broken code; it tends to break aga
Steven D'Aprano Wrote in message:
>
>
>
>
> But still complex. And you're limited by the (lack of) stability of
> Windows.
>
> If you don't *need* Windows, there is no point in running Linux on top
> of Windows in a virtual machine. It just means you're using twice as
> much memory, and you
Denis Heidtmann Wrote in message:
>
>
Please post in text, not html. Your posting program loses the
indentation in the text view, which is what most people
see.
Code:
def fib2(n):
if n==1:
return 1
elif n==2:
return 1
else:
Russel Winder Wrote in message:
> On Thu, 2014-02-06 at 18:06 -0500, Dave Angel wrote:
> [â¦]
>>
>> Code:
>> def fib2(n):
>> if n==1:
>> return 1
>>
>> elif n==2:
>> return 1
>> else:
>&g
Altrius Wrote in message:
> Hi,
>
> Iâm completely new to programming in general and everything I have read so
> far has pointed me to Python. Iâll put this another way: All I know is that
> a programming language is a medium for a human to tell a computer what to do.
> After that Iâm k
rahmad akbar Wrote in message:
Between invisible colors and a tiny font, your message is totally
incomprehensible to me. This is a text list, please post in text,
not html.
--
DaveA
___
Tutor maillist - Tutor@python.org
To unsubscribe or change
james campbell Wrote in message:
>
(Context lost because message was erroneously posted in html)
strings cannot be decoded, so there's naturally no such method.
Why not post a two line example of what you're trying, and
explain what you were expecting it to do.
--
DaveA
_
Ian D Wrote in message:
> Thanks for the help on the last one.
>
> Is it possible to restart a while loop? This doesn't work at all (surprise
> surprise)
>
> import turtle as t
>
> def start():
> global more
> more = True
>
> def stop():
> global more
> more = False
>
>
Bob Williams Wrote in message:
> to slice those lines to get the artist and album
> names into a list.
>
> So far, so good but my output contains duplicates, so my final task is
> to work out how to get rid of them.
>
Hint: a set will contain only one of each item. So if you have a
list o
Marc Eymard Wrote in message:
> ___
> Tutor maillist - Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>
Next time please post in text form rather than html, and actually
include the
Steven D'Aprano Wrote in message:
> On Wed, Feb 12, 2014 at 02:08:17PM -0500, Dave Angel wrote:
>> Marc Eymard Wrote in message:
>> > ___
>> > Tutor maillist - Tutor@python.org
>> > To unsubscribe o
On 02/17/2014 06:12 AM, Oscar Benjamin wrote:
On 17 February 2014 09:07, Aaron Misquith wrote:
The program that i'm working on just combines two files. Any help on
performing an union such that a keyword would not be repeated would be
appreciated.
Code:
with open("C:\\File1.txt") as fin1: lin
Aaron Misquith Wrote in message:
> As two others have said, a set is the simplest solution to avoid duplicates.
There are other questions to ask, however. Primary is whether
order matters.
If it does not, then observe that list(set(mylist)) will produce a
list from a list without duplicate
On 02/17/2014 05:29 AM, spir wrote:
On 02/17/2014 10:07 AM, Aaron Misquith wrote:
I have 2 different text files.
File1.txt contains:
file
RAMPython
parser
File2.txt contains:
file1234
program
I want to perform an union of these both files such that i get an output
file3.txt which contains:
On 02/17/2014 06:44 AM, Khalid Al-Ghamdi wrote:
Hi,
Why is it i can use mu custom class exception without creating an exception
object first?
Thanks
1. class ShortInputException(Exception): def __init__(self, length,
atleast):
2. Exception.__init__(self)
3. se
Oscar Benjamin Wrote in message:
> On 17 February 2014 13:16, Dave Angel wrote:
>> On 02/17/2014 06:12 AM, Oscar Benjamin wrote:
>>>
>>> Something like this:
>>>
>>> with open(r'D:\file3.txt', 'r+') as fout:
>>> keyw
Gabriele Brambilla Wrote in message:
> in the end I'm using something like this and it works:
> zipPARApha = zip(Pampli, Pgamma, Pecut, Pb, g)
> for n, (a1,b1,c1,d1,pha) in enumerate(zipPARApha):
> where the arguments of zip are lists of the same size.
Simpler would be:
for a1,b1,c1,d1,pha
Peter Otten <__pete...@web.de> Wrote in message:
> André Walker-Loud wrote:
>
>> Hello python tutors,
>>
>> I am utilizing a 3rd party numerical minimization routine. This routine
>> requires an input function, which takes as arguments, only the variables
>> with which to solve for. But I do
On 02/19/2014 07:33 AM, Oscar Benjamin wrote:
At the least I don't understand why it needs both the argument names
and the number of arguments as independent quantities. Surely
len(names) would be the number of arguments... Or am I missing
something?
In the standard library, the attributes a
Zaki Akhmad Wrote in message:
> On Thu, Feb 20, 2014 at 7:39 PM, James Scholes wrote:
>
>> Most decent Python libraries for accessing Twitter support the streaming
>> API. This lets you keep a connection to the Twitter API alive and
>> process new data as it is received. There is a simple (bu
Scott W Dunning Wrote in message:
> I am VERY new to python (programming too). I had a question regarding
> functions. Is there a way to call a function multiple times without
> recalling it over and over. Meaning is there a way I can call a function and
> then add *5 or something like that
Albert-Jan Roskam Wrote in message:
>
>
> - Original Message -
>
>> From: Danny Yoo
>> To: Peter Otten <__pete...@web.de>
>> Cc: Python Tutor Mailing List
>> Sent: Monday, February 24, 2014 11:01 PM
>> Subject: Re: [Tutor] subprocess.call list vs. str argument
>>
>> Last comment (ap
eryksun Wrote in message:
>
>
> FYI, in Windows the situation is different. CreateProcess takes a
> string argument, so the setup code changes to the following:
>
>
> It's fine to use a string for args in Windows, and you may need to if
> the program parses the command line differently than l
rahmad akbar Wrote in message:
>
>
then i realized i couldn't do something like .next() to the var in_file which
is a list. so i added a flag start = False in which will be turned to True upon
'Rich Roberts' found. is the any simpler way to move to the next element in the
list. like built in
Santosh Kumar Wrote in message:
>
Requirement : i want to call a variable assigned outside a function scope
anytime
> within the function. I read "global" is a way.
>
Your sample code doesn't do any calling. But if your design
requires you to assign to a global from inside a function, t
Santosh Kumar Wrote in message:
>
want to understand about where to use ,
viewkeys()
viewvalues()
viewitems()
..
Sometimes you want to loop through a dict, doing something with
each of the items. For example you want to generate a report.
Suppose you have a dict where the key
Bob Williams Wrote in message:
>
>>> linkName1 = pathList[j][0:-3] + "mp3"
>>
>> Isn't this exactly the same as pathList[j] ?
>>
> Actually, no. pathList[j] can contain either .mp3 files or .flac
> files. In fact the main function of the script is to run all the flacs
> through lame to conver
Scott W Dunning Wrote in message:
In addition to Ben's observation, you don't use anything random
when initializing secret. And you don't store the result of
get_guess.
--
DaveA
___
Tutor maillist - Tutor@python.org
To unsubscribe or change s
Scott W Dunning Wrote in message:
>
> On Mar 1, 2014, at 12:47 AM, Ben Finney wrote:
>
>> You've bound the name âcurrent_guessâ to the user's input, but then do
>> nothing with it for the rest of the function; it will be discarded
>> without being used.
> Hmm, Iâm not quite sure I unders
Jignesh Sutar Wrote in message:
>
>
Hi I'm trying to exclude a certain line of code if the function is called by
another function, see illustration below:
Your code example is all confused, so perhaps you are as well.
Why should any of your code in function A care who calls it? The
main po
Mark Lawrence Wrote in message:
> On 08/03/2014 01:23, Scott W Dunning wrote:
>
>>
>> def print_hints(secret, guess):
>> if guess < 1 or guess > 100:
>
> Only now do I feel that it's time to point out that the above line would
> probably be written by an experienced Python programmer as:-
hind fathallah Wrote in message:
>
>
> while rm != stars:
    print\
    """
    0 - Northe
    1 - South
    2 - East
    3 - Weast
    """
    rm = raw_input("What room you want to go?: ")
Why are you looping till he gets to th
Scott W Dunning Wrote in message:
>
Would you please stop posting in html?
>
def print_hints(secret, guess):
  if guess < 1 or guess > 100:
    print
    print "Out of range!"
    print
  if guess < secret:
    print
    print "Too low!"
  i
Alan Gauld Wrote in message:
> On 11/03/14 18:39, Al Bull wrote:
>
>
>
>> I am using Python 3.3. I did some google searches and found something
>> called dbfpy to read dbase, so I downloaded and installed it.
>>
>>File "C:\Python33\lib\site-packages\dbfpy\dbf.py", line 260
>> print re
Scott W Dunning Wrote in message:
>
> On Mar 11, 2014, at 7:50 PM, William Ray Wing wrote:
>>
>> Simple. In Mail Preferences -> Composing -> Message Format -> Plain Text
>> (Your setting is probably currently Rich Text.)
>>
> Got it, hopefully that helps.
Perfect, thanks.
--
DaveA
___
spir Wrote in message:
> On 03/13/2014 12:40 AM, Danny Yoo wrote:
>> The context is the beginning of the thread:
>>
>> https://mail.python.org/pipermail/tutor/2014-March/100543.html
>>
>> with the loop:
>>
>>
>> ###
>> while health != 0:
>> ...
>> ###
>
> The point, and reason why this
Jim Byrnes Wrote in message:
> I am reading Practical Programming - An Introduction to Computer Science
> Using Python 3. They give this example:
>
> >>> abs(-3)
> 3
>
> >>> -3 .__abs__()
> 3
>
Ben is right, dunder methods don't belong in introductory texts.
And they seldom should be ca
Saad Bashir Wrote in message:
>>> ph = float(input('Enter the pH level: '))
Enter the pH level: 8.5
>>> if ph < 7.0:
... Â Â Â print(ph, "is acidic.")
... Â Â elif ph > 7.0:
... Â Â print(ph, "is basic.")
"SyntaxError: : unindent does not match any outer indentation level.
..
Leo Nardo Wrote in message
>
>
Im on windows 8 and i need to open a file called string1.py that is on my
desktop, in both the interpreter and notepad++, so that i can work on it. I
already have it open in notepad, but for the life of me cannot figure out how
to open it in the interpreter. In
Scott W Dunning Wrote in message:
>
> On Mar 28, 2014, at 9:54 PM, Scott W Dunning wrote:
>
>> Hello, Iâm working on some practice exercises from my homework and Iâm
>> having some issues figuring out what is wanted.
>>
>> Weâre working with the while loop and this is what the questi
street.swee...@mailworks.org Wrote in message:
> I'm trying to sort the order of elements in an xml file, mostly
> to make visual inspection/comparison easier. The example xml and
> code on http://effbot.org/zone/element-sort.htm get me almost
> what I need, but the xml I'm working with has the e
Scott Dunning Wrote in message:
>
> On Mar 29, 2014, at 12:47 AM, Dave Angel wrote:
>>
>> So did your code print the string 10 times? When asking for help,
>> it's useful to show what you tried, and what was expected, and
>> what actually resulted.
>&
Scott Dunning Wrote in message:
>
> On Mar 30, 2014, at 4:29 AM, Dave Angel wrote:
>>
>> You're getting closer. Remember that the assignment shows your
>> function being called with 10, not zero. So you should have a
>> separate local variable, probabl
Scott W Dunning Wrote in message:
> Iâm working on a few exercises and Iâm a little stuck on this one.
>
> This is what the book has but it just gives me an endless loop.
>
> def square_root(a, eps=1e-6):
> while True:
> print x
> y = (x + a/x) / 2
>
Scott Dunning Wrote in message:
>
> On Mar 31, 2014, at 5:15 AM, Dave Angel wrote:
>>
>> Do you know how to define and initialize a second local variable?
>> Create one called i, with a value zero.
>>
>> You test expression will not have a literal, bu
DaveA Wrote in message:
> Gmane doesn't seem to be getting messages from either python tutor or python
> list, for the last day or two.
It's working again.
>
--
DaveA
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscriptio
Ni hung Wrote in message:
(Please post in text format, not html. It doesn't matter for
your particular message, but several things can go wrong, where
some or most of us do not see what you meant to post)
> I am learning programming using python. I think of solving a
> problem using functi
Jared Nielsen Wrote in message:
> Hi Pythons,
> Could someone explain the difference between expressions and statements?
> I know that expressions are statements that produce a value.
> I'm unclear on functions and especially strings.
> Are any of the following expressions?
>
> print(42)
> print(
uga...@talktalk.net Wrote in message:
> ___
> Tutor maillist - Tutor@python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
>
A message left in invisible ink. Please post in text form, not
html,
uga...@talktalk.net Wrote in message:
>
Please write in plain English if you want to be understood
Like the op, you post in html. There are a bunch of things that
can wrong when you do that, so you should use text mail instead.
In the case of the op, he apparently changed the text color to
Saba Usmani Wrote in message:
>
>
You posted in html so I can't quote your code, but why aren't you
using int() to convert in one call? Second argument is the base
to be used.
value = int ("10011", 2)
othervalue = int ("234") # default to decimal
--
DaveA
_
"Wheeler, Gabriel" Wrote in message:
>
(not much I could read there. This is a text mailing list, so
please tell your mail program to send in text mode, not html.
Only parts of your code were visible here, and your question not
at all. Fortunately, Peter quoted all or most of your message.
H
Alan Gauld Wrote in message:
> On 19/04/14 21:48, Vipul Sharma wrote:
>
>> *if a == 5 and b == 5:*
>> *# do something*
>>
>> *if a == b and b == 5:*
>> *# do something *
>>
>> which made me think, is there any difference between the two ?
>
> Yes.
> I don't know how python actually does
Saba Usmani Wrote in message:
>
>
If for some reason you can't read this code properly as outlook has formatted
it to
>look messy/cluttered; you do not have to respond
It'd save trouble if you continued in the same thread you
started, instead of repeatedly starting a new one. And you
Jorge Leon Wrote in message:
>
I think Steven has nailed your main problem, but I have two other
suggestions:
Use text mail, not html. This is a text list, and it can make a
difference in half a dozen ways. Any decent email program has a
way to select that.
When showing an error, include
baidusandy Wrote in message:
[invisible message not copied here]
By posting in html, you managed to pick black on black text. I
literally could see none of your message except the boilerplate.
Please tell your email program to use text mode.
--
DaveA
_
Jorge Leon Wrote in message:
> Thank you Steve and Dave for the prompt response and advise, and sorry
> about the format.
>
> The version of Python I'm working under is 2.7.5. About the .super():
> I'm going to try out the format you gave me for the files, and yes:
>
Hobie Audet Wrote in message:
>
It would be much better if you used text emails to post on this
text list, rather than html. For one thing, your indentation
might not be messed up. For another, I might be able to do
proper quoting.
>
(you wrote):
My code looks something like this:
Chris Wrote in message:
> Hi,
>
> I'm a Python Newbie. Probably, this is a simple question.
But what is your context? Your Python version (apparently 2.x,
since you're using print as a statement, rather than a function)?
What os, and what is stdout pointing to, since you're pretending
that y
You both posted in html, rather than text mode.
Joel Goldstick Wrote in message:
>
>
>
> 1. what is line means? mask[c] |= bit
> This bitwise or. It sets the rightmost bit in masks[c]
Only the first time through the loop, when bit == 1
--
DaveA
Leo Nardo Wrote in message:
> I want to program. I enjoy programming and am willing to put in time
> to do this.When I try to get started with programming I realize how
> difficult it is to find the information worthy of learning.
> I would like to write the
> program in python, and I do not nee
rahmad akbar Wrote in message:
>
>
to Dave,
> i do i do the text mode? i had no idea this was on html
Whatever mail program you're using is apparently defaulting to
html. Find a menu item that specifies 'text' or 'plain text' or
'text only'.
jordan smallwood Wrote in
message:
Do you know what a module is? Can you use a text editor to create one?
Do you know what a function looks like? Try writing the first one
they asked. Post it here, along with some test code showing it
works, or describe what goes wrong.
And while you're
Ian D Wrote in message:
> Can anyone clarify please?
>
>
> Just reading this:
>
> https://wiki.python.org/moin/BitwiseOperators
>
>
> The section on 2's complement binary for negative integers.
>
>
> It states:
>
>
> "Thus the number -5 is treated by bitwise operators as if it were writte
C Smith Wrote in message:
>
>
I had always assumed that append() was more efficient, but some recent
discussions seem to point at that it is the same as append(). Which is
preferable and why?
Please be more explicit, preferably with example code.
list.append and list.__add__ don't even do th
jordan smallwood Wrote in
message:
>
> want to have the user try again if they enter in a non integer. What am I
> missing:
Do you perhaps mean float?
If so, see the other response.
--
DaveA
___
Tutor maillist - Tutor@python.org
To unsubscr
Danny Yoo Wrote in message:
>
>
>
>
>> Hopefully, this makes the point clearer: we must not try to decode
>> individual lines. By that time, the damage has been done: the act of
>> trying to break the file into lines by looking naively at newline byte
>> characters is invalid when certain cha
Alan Gauld Wrote in message:
>>> (not a copy!) to the sorted item.
>>
>> sorted() does make a copy of the list:
>
> Really? That's a bummer.
> I assumed (never assume!) that it returned a reference to the original.
> I really, really, hate the way Python handles this :-(
>
It's not clear to me
C Smith Wrote in message:
> Sorry.
>
> I meant for example:
> list1 = [1,2,3]
> list2 = [3,4,5]
>
> newList = list1 + list2
>
> versus
>
> for x in list2:
> list1.append(x)
>
> Which is the preferred way to add elements from one list to another?
Thank you for switching to text mail.
The
Denis Heidtmann Wrote in message:
> On Sun, May 4, 2014 at 6:44 PM, Dave Angel wrote:
>> C Smith Wrote in message:
>>> Sorry.
>>>
>>> I meant for example:
>>> list1 = [1,2,3]
>>> list2 = [3,4,5]
>>>
>>> newList = lis
On 05/10/2014 11:16 PM, Glen Chan wrote:
Hello, I am a student trying to figure out Python. I am getting errors that I
don't know how to fix. What do you do after you get the error message and
something is highlighted? Does that have to be deleted? Anyway, here is what I
mean...
def main():
On 05/14/2014 05:45 AM, Sam Ball wrote:
I'm attempting to create a program where the user inputs their account number
(which must be 8 digits) and if what the user enters is not 8 digits in length
I want python to tell the user this is invalid and then keep asking for the
account number until
On 05/14/2014 04:48 PM, JEAN MICHEL wrote:
I'm a Python beginner
Welcome to python-tutor
trying write a program that reads outside txt files,
What's an "outside txt file"? And since you only one file, perhaps you
left out the othertwo?
takes the data like the name and test grades of s
Shweta Kaushik Wrote in message:
> Hi All,
>
> I am new to python. Please help me.
> I have to create one function which can set values sent by user from a list
> of values.
>
> For eg:
> I have a list having values between 1 to 100.
> List = ['1', '2', ... '100']
>
> I have to write a functi
fabu desay Wrote in message:
> If I got the problem correctly
What problem is that? I see no context.
> ,you can equally create + open a file
> file = open(filename,+wr)
But the second argument must be a string. I cannot imagine any
content in the wrong variable that would produce a strin
questions anon Wrote in message:
>
Please use text mail to post, as html has a number of problems.
In your current message, indentation is lost. Also don't
top-post in this forum. Any selective quoting of previous context
should precede your comments.
Your logic presently tries to copy a d
1801 - 1900 of 2089 matches
Mail list logo