Threads for redsymbol

  1. 4

    I am the author of Powerful Python. This excellent article inspires me to make a few comments:

    Obsession. There’s an old saying that you should only write a book if you have to. Meaning, you have some message inside that you MUST get out to the world, regardless of personal cost.

    I don’t think that is strictly true, but it was certainly true in my case. I was obsessed; in a real sense, I had no choice but to write this book.

    That obsession proved useful in pulling me through the terrible immensity of work required. As one example, I rewrote the chapter on scalability and generator functions from scratch 15 times before it felt right. Yes, FIFTEEN times. I wish I was exaggerating.

    Catharsis. When I got the final print copy of Powerful Python in my hands, it was the most beautiful book I had ever seen. I cannot put into words what it was like. I still get emotional thinking about that moment.

    Legacy is a valid reason to write a book. I have made quite a bit of money from Powerful Python (more on that below), but had I made nothing, I would still be glad I wrote it, just from the impact it has had on engineering teams around the world.

    I own a gazillion books, most of which probably never made the author much money. But a book you write may change the arc of someone’s life years from now. That means something.

    Royalties. Martin’s assessment of the financial outcome is spot on. You MIGHT win the lottery and write a Harry Potter novel. But probably not.

    Publisher. Martin published with O’Reilly. Based on having worked with them a lot on other projects, I recommend them as a publisher. They are great people and I enjoyed every project we did together; I am certain publishing a book with them would be great.

    However, I chose to self-publish Powerful Python. We talked back and forth a lot, but in the end I wanted more control than they were willing to give me over the distribution and some other matters. Which leads me to the next point:

    Monetizing. Being an entrepreneur to the bone, I used the authority of Powerful Python to build a whole training company, teaching more advanced professional programming skills in a hands-on way.

    THAT was the real moneymaker. From a cold bean-counting perspective, Powerful Python was just a hyper-effective brochure.

    Our community likes to romanticize entrepreneurship. But pulling this off requires tremendous grit and boldness in the face of ghastly risk. Most people just do not have that inside of them.

    In comparison, writing the book is EASY. I would love to say anyone can build a company from their book, and earn a lot of money that way. But you will have to decide if you are willing to pay the price if you want to go this route.

    1. 2

      I’m the author of a book on intermediate/advanced Python programming, and the founder of a company that does professional Python training.

      I am in total agreement with this article.

      For a starting CS student, laying a solid foundation matters more than anything else at the start. Python is a light-saber chainsaw when it’s used by someone with that strong foundation, but makes a creaky foundation itself.

      Also, and this doesn’t matter as much, but I was delighted he concluded Scala was a great starting language. That’s what I would have picked too.

      (By the way, a large part of Python’s market is people who are not CS majors, but smart individuals who suddenly find they must do some coding as part of their job. The above doesn’t apply to them; the ROI of their time/energy is better leaping head-first into Python. It also doesn’t apply to type A data scientists, though it might apply to type B and probably to data engineers.)

      1. 1

        It also doesn’t apply to type A data scientists, though it might apply to type B and probably to data engineers.

        I am unfamiliar with Type A and Type B data scientists, where can I learn more about this concept?

        1. 2

          I believe the original distinction was made my Michael Hochseter:

          That Quora post of his inspired quite a few other articles - search for “type a type b data scientist” and you’ll have plenty to read.

      1. 10

        He makes some points about why Python mightn’t be the best choice but… SCALA? REALLY?

        It’s clearly an amazingly capable language, but to quote Christian Beedgen “Scala is a VERY sharp tool.”.

        I honestly don’t understand how a language with so many potential pitfalls for the unwary could be a good choice for a first language?

        1. 2

          I think it’s a great choice, but I agree it’s an imperfect razor sharp tool. What language would you choose instead?

          1. 4

            Thinking about this, this is the ULTIMATE bikeshed question, is it not? :)

            So, let me first admit that I am poorly qualified to make that distinction. I am not a teacher and by most measures I’m not even a computer scientist.

            I’m a sysadmin -> release engineer -> software developer who was raised by wolved cobbling together process oriented automations using shell, Perl, Ruby and Python as my skill set evolved, in that order :)

            The thing I keep coming back to, and where I part ways with most better qualified folks on this topic is: I like abstraction, and I know for myself that my interest in programming only REALLY blossomed when I encountered languages that presented themselves to me at a high level of abstraction.

            So, I can see where Scala could actually be nice, in that you could teach basic OOP which is a nice easy conceptual framework for students to absorb, but get into some of the more ascetic levitation and flying functional stuff later as they develop their chops.

            As to what I would pick? I’d pick Python. I don’t personally feel stunted for life from learning other languages because of my preference for it, and I think that giving students a tool that will allow them to experience high velocity development is a great way to start.

            1. 2

              I agree that Scala is a sharp tool, but I think that’s the point. Those pitfalls typically show themselves right away in the form of syntax errors. When speaking of languages like Scala or Haskell, people often say: if it compiles, it’s probably correct. I definitely can see that feedback being valuable for teaching students. And because Haskell’s errors can be quite arcane, Scala seems like a better choice.

              Anecdotally, my partner went to Trinity. The author of this post was her professor, and she learned Scala. Though she only took that one class, and hasn’t written any code in the years since, she still understands concepts like types, OO, and functional programming when I talk to her about them.

              1. 1

                You’re actually supporting my bikeshed argument :)

                Given a superlative teacher you can derive tremendous value whatever the choice of language. Scala is probably an excellent choice for this person and their students for all the reasons you outlined.

                The question is - for everyone who won’t have the benefit of Professor Amazing at Trinity, is Scala the right first language?

                The answer may well be yes. I really don’t know.

            2. 1

              I don’t think the language per se makes any difference; what matters is the tooling, and the instructor. I did SICP at Chicago back in the dark ages, but aside from leaving me with a deep fondness for Lisps, the fact that it was Scheme and not, say, Pascal was almost irrelevant.

          1. 3

            I’ve long thought it would be powerful to design a four-year CS degree program around compilers.

            The first course wouldn’t start until the second year. Maybe in the last semester/quarter, maybe several different compiler courses throughout that second year. Starting in the 2nd year allows concepts to be gently and gradually introduced, while also “weeding out” those who can’t hack it.

            And from then on, students would always be enrolled in some sort of course in compiler design and construction. Throughout their 3rd and 4th year, every semester. Building up deeper knowledge about all those topics a typical single compiler course shreds through at warp speed.

            Imagine someone coming out that degree program, being able to design and implement compilers as easily as most devs can create a standard reusable library.

            Because most people who get a CS degree only ever have just one compiler course - and a lot don’t even have that, apparently. We barely retain what we crammed in our heads in that exhausting, over-packed course. And that’s why we rarely create parsers and DSLs when we’re on the job - much less full-fledged compilers.

            How would our profession be different if this was a standard skill?