[Tutor] Checksum program

Lezlie Kline lezlie.kline at gmail.com
Wed Mar 23 16:11:04 CET 2011


I have a question for the list about the homework rule and the tutoring
list.  If you have a question and you're not asking for your homework or
past homework to be done for you but you just have questions to be explained
isn't that what tutoring and learning is all about.  For example, on my
question here.  I have a problem that is not homework for a grade and I
don't understand it.  I can't find a tutor.  I'm frustrated and you guys can
provide help for my understanding which you were doing.  Not by giving me an
answer, but by asking me questions and helping me to understand.  Isn't that
what tutoring and open forum is all about.  Unfortunately, I still don't
quite have it I feel like I got left hanging on the edge of almost...

I called the Dean of Graduate students at NC State to try to find someone to
tutor me and the response was helpful but Python isn't taught at NC State.
UNC - the same.  Wake Technical - the same.  I've looked on Craig's list and
Googled with no luck  I'm taking an intro to computer science class online
through Utica for Cybersecurity and I would just like some help
understanding.  I'm not one to easily give up!!

Anyway, I understand having rules and why, but I also think that when those
rules don't make sense under the situation exceptions should be made.  Just
saying...

L.

On Wed, Mar 23, 2011 at 10:54 AM, taserian <taserian at gmail.com> wrote:

> When replying to the Python Tutor list, please use "Reply All" instead of
> just "Reply". I meant to put this in my previous message, but it remained in
> "meant to" phase and never got implemented properly. 8-)
>
>
>  I don't think it's been initialized properly, but that's where I don't
> understand about the accumulator for strings.  I originally thought this for
> the accumulator:
>
> output=""
> for i in range(len(message[i])"
>
>
>>>>     print"The value of message[i] is ", message[i]
>>>>     output=output+" " + ord(message[i])
>>>>
>>>>     print"The value of the message is ", output
>>>>
>>>> but strings and integers don't concatentate AND my ord(value) isn't
>>>> accumulating AND I thing my output is getting overwritten.
>>>>
>>>  You don't want to mix apples and oranges. Your variable "message"
>>> contains a full name in the test case, "John X. Doe", for example, so it's
>>> made up of characters. What should the accumulator contain, if you're going
>>> to be adding numbers? Numbers
>>>
>>
> Then your code above should look something like this:
>
> output= 0
> for i in message:
>     print"Character i in message: ", message[i]
>
>     output=output + ord(message[i])
> print "The value of the message is ", output
>
>
> In pseudocode:
> Start with the value for an empty message in the variable "output".
> For every character in "message":
>     Print the character
>     Add the ASCII value of the character to the accumulator "output".
> After all of the characters have been processed, show the final value of
> "output"
>
>
>>
>>> Is this homework? Not anymore  I'm past that and I live in NC and I've
>>> been desperately looking for a tutor but I'm having difficulty finding
>>> anyone who does Python programming.  They don't teach it at NC State or UNC
>>> or Wake Tech.  If you don't want to help.  I understand.  This was my last
>>> resort.
>>>
>>
>>>
>>
> Not at all. It's just that we have a rule about not doing anyone's homework
> on the list. It robs them of the learning experience, and can provide a
> grade which hasn't been earned properly.
>
> Tony R.
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20110323/348a1509/attachment-0001.html>


More information about the Tutor mailing list