J
John Allsup
What is needed for proper learning is near-absolute simplicity.
Even one toy too many to play with is an intolerable distraction,
but one too few massively hampers learning and induces boredom.
I want to be able to say:
1. Put a nice picture on the background.
2. Put a terminal window with, say, 64x20 lines, dead centre.
3. Run a simple REPL program written in Python or Ruby within it.
I do not really want to write any more lines of code than I need to.
Why do we not have langauges and libraries that can do the above
with only five lines of code (line 0 == setup, line 4 == cleanup).
Programming should be that efficient if we learn to make things
beautiful and not tolerate wastes of lines and characters, on
a global scale as well as locally to our projects.
Consider
====
#!/usr/bin/env python3
from myappfw import app
from myapp1 import repl
app.background = "Moutains1"
t = app.terminal.open(title="Typing commands One Oh One",position="centre",
width="80%",height="72%",rows="20",columns="64")
exit(t.run(repl))
====
What Python would I need to write, as concise but readable as
practically possible, so that the above program works as desired (for
any repl that obeys the basic input-process-output behaviour of a repl)?
This is top-down design done right IMO (as described in Thinking Forth,
by the way).
Even one toy too many to play with is an intolerable distraction,
but one too few massively hampers learning and induces boredom.
I want to be able to say:
1. Put a nice picture on the background.
2. Put a terminal window with, say, 64x20 lines, dead centre.
3. Run a simple REPL program written in Python or Ruby within it.
I do not really want to write any more lines of code than I need to.
Why do we not have langauges and libraries that can do the above
with only five lines of code (line 0 == setup, line 4 == cleanup).
Programming should be that efficient if we learn to make things
beautiful and not tolerate wastes of lines and characters, on
a global scale as well as locally to our projects.
Consider
====
#!/usr/bin/env python3
from myappfw import app
from myapp1 import repl
app.background = "Moutains1"
t = app.terminal.open(title="Typing commands One Oh One",position="centre",
width="80%",height="72%",rows="20",columns="64")
exit(t.run(repl))
====
What Python would I need to write, as concise but readable as
practically possible, so that the above program works as desired (for
any repl that obeys the basic input-process-output behaviour of a repl)?
This is top-down design done right IMO (as described in Thinking Forth,
by the way).