<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
--></style>
</head>
<body class='hmmessage'>
<br>> <br>> On Mon, Mar 8, 2010 at 3:31 PM, wooks . <wookiz@hotmail.com> wrote:<br>> >> You could implement a<br>> >> immutable swap (i.e. a copy) to show the students the mutation is not<br>> >> fundamental.<br>> >><br>> ><br>> > but<br>> > a) but would it further the objective of clarity<br>> > b) is it relevant to their syllabus<br>> > c) would they care?<br>> <br>> I can safely answer "I don't know" to all the above :) But I think the<br>> main point you started with was imperative vs functional style, in<br>> which case I think Matthias has shown that normal functional style<br>> (i.e. no do loop) can be very clear. At least I find his final bubble<br>> sort very clear to read and your students may do so as well given it<br>> doesn't require them to internalise any new syntax.<br>> <br><br><div>Teaching them do syntax has become an objective of the exercise. It fits with the syllabus I am lumbered with.</div><div><br></div><div>Following your ringing endorsement I'll show Matthias's version as well (as well as learn from it myself).</div><div><br></div><div><br></div>                                            <br /><hr />Do you want a Hotmail account? <a href='http://clk.atdmt.com/UKM/go/197222280/direct/01/' target='_new'>Sign-up now - Free</a></body>
</html>