<br><br><div><span class="gmail_quote">On 8/3/07, <b class="gmail_sendername">kirby urner</b> &lt;<a href="mailto:kirby.urner@gmail.com">kirby.urner@gmail.com</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
On 8/3/07, Andre Roberge &lt;<a href="mailto:andre.roberge@gmail.com">andre.roberge@gmail.com</a>&gt; wrote:<br><br>&gt; Kirby got a good point - however, I think that you&#39;d still get the &quot;hook&quot;<br>&gt; with newbies without the automatic echoing that Michael describes.
<br>&gt;<br><br>Not sure we should call this &quot;echoing&quot; as what&#39;s happening<br>is an expression is being evaluated.<br><br>It just so happens that the eval of a quoted string returns<br>itself&nbsp;&nbsp;whereas &quot;some expression with %s&quot; % &quot;substitution&quot;
<br>would actually evaluate to non-echo.<br><br>kirby@dell:~$ python ./repl.py<br>&gt;&gt;&gt; &#39;THIS IS A STRING&#39;<br>THIS IS A STRING<br>&gt;&gt;&gt; [x*x for x in range(10)]<br>[0, 1, 4, 9, 16, 25, 36, 49, 64, 81]
<br>&gt;&gt;&gt; &quot;1-2-3 %s&quot; % &quot;testing&quot;<br>1-2-3 testing<br><br>Would one turn off all of the above, or just the first eval-print?<br><br>What would be the point of a broken shell, vs explaining that<br>
Python, like many languages, features a REPL (read-eval-print loop)?<br><br>Kirby<br></blockquote></div>I don&#39;t see it as &quot;either or&quot;, but as &quot;why not allow both?&quot;.&nbsp;&nbsp;&nbsp; I agree entirely with the strength of the REPL.&nbsp; However, when going from that to having code saved in a file and executed, a huge step occurs (which is what Michael was referring to I believe) in that to see something output, the user *must* put in an explicit print statement.
<br><br>What I envisage right now is to continue to have the default shell using in Crunchy (prompt = &quot;&gt;&gt;&gt;&quot;) and give the possibility to have a &quot;parrot&quot; shell (obligatory Monty Python reference; he&#39;s not dead.&nbsp; He may not be replying ... but he&#39;s just sleeping).&nbsp;&nbsp; Perhaps the prompt could be
<br><br>u_)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (parrot lying on its side, two feet up, beak pointing up; sorry Kirby, the parrot&#39;s ribs are too small to see).<br><br>I could see a teacher giving a few interactive examples with this shell, have the students play with it for a short while, and then move on to saving files and running them.&nbsp;&nbsp;&nbsp;&nbsp; ... Just something to ease the transition from the friendly REPL to writing standalone scripts.
<br><br>@Michael: is this what you had in mind?<br><br>André<br>