[Tutor] Tutor Digest, Vol 196, Issue 28

Krish P krishp52 at rocketmail.com
Sun Jun 14 21:34:31 EDT 2020


 Hi, thanks for your response.
I not able to generate the Syracuse sequence for each of those numbers in the data.txt file.
given is the code that I came up with:
def syr(x):    if x % 2 ==0:        return x/2    else:        return 3*x + 1  def main():    x = 50    print(x*"-") # Line Break (LB)    print("Program use Syracuse sequence to reach 1 from")    print("natural numbers by utilizing a set of data.")    print(x*"-") # LB
    f = open("data.txt", "r")    print(f.read())
    main()

Waiting for your kind assistanceThanksKrish    On Monday, June 15, 2020, 12:13:14 PM GMT+12, <tutor-request at python.org> wrote:  
 
 Send Tutor mailing list submissions to
    tutor at python.org

To subscribe or unsubscribe via the World Wide Web, visit
    https://mail.python.org/mailman/listinfo/tutor
or, via email, send a message with subject or body 'help' to
    tutor-request at python.org

You can reach the person managing the list at
    tutor-owner at python.org

When replying, please edit your Subject line so it is more specific
than "Re: Contents of Tutor digest..."


Today's Topics:

  1. Re: python (Alan Gauld)
  2. Re: python (DL Neil)
  3. Re: python (Alan Gauld)
  4. Re: python (Oscar Benjamin)
  5. Re: python (dn)


----------------------------------------------------------------------

Message: 1
Date: Sun, 14 Jun 2020 18:43:56 +0100
From: Alan Gauld <alan.gauld at yahoo.co.uk>
To: tutor at python.org
Subject: Re: [Tutor] python
Message-ID: <rc5nkt$3mht$1 at ciao.gmane.io>
Content-Type: text/plain; charset=utf-8

On 14/06/2020 13:09, Krish P via Tutor wrote:
> ...your assignment specifications ...to create a program that will read all this data
> from the file and generate the Syracuse sequence for each 

> 2. Additionally, you have to write every one of these Syracuse sequence> into a file calledSyra.txt using your code.

It looks like you got a reasonable description of the problem to be
solved. How did you get on? Got any code yet? Does it work?
If so, well done!

If not, how would you like us to help?

What error messages do you get?
How close is the data out to what you expected?
What aspects of the assignment do you not understand?
Which OS are you using? Which python version?
Do you have programming experience in other languages?
Or are you a beginner?

The more you help us the more we can help you.

-- 
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos




------------------------------

Message: 2
Date: Mon, 15 Jun 2020 08:49:41 +1200
From: DL Neil <PyTutor at danceswithmice.info>
To: tutor at python.org
Subject: Re: [Tutor] python
Message-ID: <2b2ed393-7001-1e06-0106-5860bca574f9 at DancesWithMice.info>
Content-Type: text/plain; charset=utf-8; format=flowed

On 15/06/20 12:09 AM, Krish P via Tutor wrote:
> The Syracuse (also called the Collatz Hailstone) sequence...
> Problem to be SolvedYou will find a data file on Moodle alongside your assignment specifications...


In case you have not met "Moodle" before, it is an LMS (Learning 
Management System). It can be thought-of as a Content Management System 
with add-ons specifically designed for training, eg presenting lectures 
and papers, references, quizzes and exams, and so-forth. Think of it as 
the on-line equivalent of the binders of 'stuff' we used to accumulate 
as the academic year progressed (or the teacher's equivalent thereof).


Something else, of which you may be unaware: Another characteristic of 
today's education is that as well as the on-line teaching materials, 
there are also 'services', often known as "paper mills" or "term paper 
writing services", which offer to complete academic works - in exchange 
for money. Surprise, shock, horror! Thus, plagiarism and other enablers 
of 'cognitive by-pass learning' have exploded into a massive problem and 
dilute the value of certifications and degrees.


The OP was brutally honest that this is an academic assignment, even if 
what was being asked of us was unclear!

I wouldn't like to suggest that the OP thought us a 'paper mill' for 
ComSc, but the post is exactly how one might present to such. (the 
expected response being a $quotation for the work)


All of which may help to explain (if you are sometimes mystified by an 
apparent, and yet uncharacteristic, lack of 'helpfulness') why some of 
us *deliberately* avoid giving a direct answer to some posts. Instead, 
we will point to references where learning should take-place - and thus 
the *actual objective* be achieved. ("Socratic approach", 'engendering 
curiosity', blah, blah, psychology...)
-- 
Regards =dn


------------------------------

Message: 3
Date: Mon, 15 Jun 2020 00:29:36 +0100
From: Alan Gauld <alan.gauld at yahoo.co.uk>
To: tutor at python.org
Subject: Re: [Tutor] python
Message-ID: <rc6bt0$32qe$1 at ciao.gmane.io>
Content-Type: text/plain; charset=utf-8

On 14/06/2020 21:49, DL Neil via Tutor wrote:
> there are also 'services', often known as "paper mills" or "term paper 
> writing services", which offer to complete academic works - in exchange 
> for money. 

I can't pretend to begin to understand the rationale for
using such a service.

Does such a student expect to get a job after qualifying? If they
can't even do the near trivial assignments given out in
school/college how do they expect to do a job in the real
world with real problems?

Such a service would never have succeeded in my time at school,
students were in perpetual penury and could never afford to
employ such a thing! Of course that was before "student loans"
became a thing... :-/

-- 
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos




------------------------------

Message: 4
Date: Mon, 15 Jun 2020 01:09:04 +0100
From: Oscar Benjamin <oscar.j.benjamin at gmail.com>
To: Alan Gauld <alan.gauld at yahoo.co.uk>
Cc: tutor <tutor at python.org>
Subject: Re: [Tutor] python
Message-ID:
    <CAHVvXxSE6VmCDdSv6eOq-6qEWgw=k4bAUFMb9bdb-PLaEw-R2w at mail.gmail.com>
Content-Type: text/plain; charset="UTF-8"

On Mon, 15 Jun 2020 at 00:30, Alan Gauld via Tutor <tutor at python.org> wrote:
>
> On 14/06/2020 21:49, DL Neil via Tutor wrote:
> > there are also 'services', often known as "paper mills" or "term paper
> > writing services", which offer to complete academic works - in exchange
> > for money.
>
> I can't pretend to begin to understand the rationale for
> using such a service.

Speaking as someone who teaches introductory programming to
undergraduate Engineering students I've seen this happen and in my
experience it comes more from desperation then calm rational thinking.

> Does such a student expect to get a job after qualifying? If they
> can't even do the near trivial assignments given out in
> school/college how do they expect to do a job in the real
> world with real problems?

Our students after graduating (as Engineers) will go on to do many
different things. Some of them will become professional programmers
and many more will be able to make use of their programming skills but
most will not really do any programming after graduating. We hope they
learned something from the experience of programming even if it
doesn't become a core part of their future career. I can see though
that some students think that programming units are just a hoop that
they might successfully go round rather than jump through.

> Such a service would never have succeeded in my time at school,
> students were in perpetual penury and could never afford to
> employ such a thing! Of course that was before "student loans"
> became a thing... :-/

There is significant variability in the wealth of students. There are
plenty enough who can afford to pay for these kinds of services that
it is clearly a viable business for those offering the services.
Whether it's viable for the customers is a different question:
generally the cases I know of do not lead ultimately to academic
success (i.e. graduation). Unfortunately I can't speak for the cases I
*don't* know of...

--
Oscar


------------------------------

Message: 5
Date: Mon, 15 Jun 2020 12:11:37 +1200
From: dn <PyTutor at danceswithmice.info>
To: tutor at python.org
Subject: Re: [Tutor] python
Message-ID: <453d29e7-2036-c419-4558-41929363d390 at DancesWithMice.info>
Content-Type: text/plain; charset=utf-8; format=flowed

On 15/06/20 11:29 AM, Alan Gauld via Tutor wrote:
> On 14/06/2020 21:49, DL Neil via Tutor wrote:
>> there are also 'services', often known as "paper mills" or "term paper
>> writing services", which offer to complete academic works - in exchange
>> for money.
> 
> I can't pretend to begin to understand the rationale for
> using such a service.
> 
> Does such a student expect to get a job after qualifying? If they
> can't even do the near trivial assignments given out in
> school/college how do they expect to do a job in the real
> world with real problems?
> 
> Such a service would never have succeeded in my time at school,
> students were in perpetual penury and could never afford to
> employ such a thing! Of course that was before "student loans"
> became a thing... :-/


The rationale is actually quite evident: when one arrives at university 
(or...), it doesn't take long to discover that there are some (other) 
extremely intelligent folk who might well be 'better' than you are. 
Plus, there are the usual 'pressures' of "time" and total-disasters when 
it comes to the skill of making the best use of one's time.

Another is 'competition' and the pressures of "continuous assessment" 
(numbers of tests/contributors to the final grade throughout the course) 
cf the once-uniform 'it all comes down to the final-exam' 
course-approach. Accordingly, one can't have 'an off-day' because every 
piece of work 'counts'. (sort of like paid-employment then!)

Accordingly, the temptation of finding any 'short-cut'.


You have touched-upon one of the reasons why I prefer the (old) 
technical institute/polytechnic/community college approach to *training* 
as opposed to the university approach to *education*. (if you don't 
understand the significance or subtlety of this comment, prepend "sex" 
to those two words and consider if they are 'the same'!) Unlike 
yourself, I do not teach/train Python, but do other languages and 
tech-skills. We both want to see employable 'graduates', either as 
trainer or as employer.

What we are seeking is "Mastery". Can the person (now) *do* the 
job/task/write the program(me)? Do, or die!

Does a student, faced with a likely 'fail' think about his/her future 
employment - or is (s)he all-consumed by securing a (good) pass for the 
current assignment?


Don't get me started on the economic fallacies of 'student loans'!

You must have been 'a good, little, boy'. Such services were very much 
available (in a different form) when we were at-school (walking miles 
each-way, no shoes, knee-high snow, fearful of attacks by dinosaurs...). 
There were always seniors/post-grads, etc, who were keen to 'make a 
quid/buck'. However, their lives were very much more risky because the 
institution could easily detect what was a-foot AND could reach-out and 
grab the miscreants for suitable punishment. These days, the student and 
'ghost-writer' could be continents apart - and far from the reach of 
'justice'!

My first job at the university was as a marker (grader, these days 
perhaps "teaching assistant"). After a date-due, I would receive 
hundreds of multi-page printouts of COBOL or FORTRAN, and results. 
(could fill a small suit-case!) A few days later, I would return to the 
lecturer and drop multiple distinct piles on his desk. The 'good pile' 
was the distinct and passing efforts. The 'bad pile' was distinct but 
failing results. The other piles were all 'copies' - each member of the 
pile (and there were often dozens) were essentially identical - but the 
different piles of 'copies' were differently characteristic.

I was always grateful that I didn't have to (a) identify who was the 
original author whose work passed/failed, or (b) decide how to mark 
(grade) or punish such. He repeatedly gave me 'glowing recommendations' 
because of the revelation of my ability to 'see' such patterns (which 
habit one would expect from systems analysts and designers, so shouldn't 
be 'that' special!).

So, "nothing new under the sun" then!
-- 
Regards =dn


------------------------------

Subject: Digest Footer

_______________________________________________
Tutor maillist  -  Tutor at python.org
https://mail.python.org/mailman/listinfo/tutor


------------------------------

End of Tutor Digest, Vol 196, Issue 28
**************************************
  


More information about the Tutor mailing list