Categories
Career Programming What I’m Up To

What you’ll learn in my online course: Using Python to detect startup founder megalomania

Poster for the Apple TV+ series “WeCrashed”.
WeCrashed was a good podcast and a great TV miniseries.

One of the more ridiculous aspects of the S-1 Form that WeWork filed during their first attempt at an IPO was the fact that the name “Adam” (WeWork’s founder / personality behind the cult Adam Neumann) gets mentioned in it a ludicrous number of times. It’s not unusual for an S-1 Form to mention the founder’s name a couple dozen times, but nowhere near as many times as WeWork’s original S-1 did.

You could go through WeWork’s S-1 and count the number of times “Adam” appears in its text. You could load WeWork’s S-1 into a text editor and have it give you that number. But what if you had to do that for a dozen, or a hundred, or a thousand companies and create a list of the number of times each company’s founder was mentioned in its S-1? You will write a Python script to do just that in my upcoming course.

I’ll guide you through the process of writing that script and running it on not just the text of WeWork’s S-1, but also for other hot tech companies, such as Zoom, Uber, Lyft, and Slack.

It’s just one of the practical things I’ll cover in the Learn Python online course being offered by Computer Coach. Here are the quick details:

  • What: An introductory Python course!
  • Where: Online, via Zoom.
  • When: Monday and Wednesday evenings, from 6 p.m. to 10 p.m., starting Wednesday, September 7th.
  • How to enroll or find out more: Contact Computer Coach’s Kasandra Perez at kasandra@computercoach.com or (813)-254-6459 to find out more about the course or register.
Banner: Computer Coach - Learn Python - Live, online, instructor-led - Starting September 7th 2022

For more details, see this post: I’m teaching another 5-week / 10-evening Python course starting September 7th!

Categories
Career Programming What I’m Up To

I’m teaching another 5-week / 10-evening Python course starting September 7th!

If you’re getting this feeling…

…and you’d rather have this feeling…

Creative Commons image by Nick Youngson — CC BY-SA 3.0 Pix4free.
Click here to see the source.

…then the course I’m teaching might help:

a close up of text and logo over a white background
Graohic: Computer Coach Training Center logo

I’ve been programming in Python since 1999, and I’ll be teaching Computer Coach’s upcoming 10-week online Learning Python course!

The “TL;DR:”

  • What: An introductory Python course!
  • Where: Online, via Zoom.
  • When: Monday and Wednesday evenings, from 6 p.m. to 10 p.m., starting Wednesday, September 7th.
  • How to enroll or find out more: Contact Computer Coach’s Kasandra Perez at kasandra@computercoach.com or (813)-254-6459 to find out more about the course or register.

What will you get out of this course?

The biggest things that you’ll get out of this course are the tools to succeed in a tech career, namely:

  • An introduction to the most-used and most useful parts of the Python programming language,
  • a solid basis in programming principles,
  • and a bag of tricks that you can use in your tech career.

The course will use one of the best books on Python out there: Automate the Boring Stuff with Python by Al Sweigart (whom I had the pleasure of meeting in person earlier this year at PyCon):

…but we won’t just stick to the book. We’ll look at all sorts of programming examples and tricks, based on your suggestions or needs. These include (and aren’t limited to):

  • CoverTron: My generator for cover letters for job applications. I actually used it in my last job search!
  • Tampa Bay Tech Events Transmogrifier: Every week, I put together a list of tech events for Tampa Bay, culled from Eventbrite and Meetup. It would take me hours to do it by hand, but it’s so much quicker with the automated help of a couple of Python scripts.
  • Find out when and where a digital photo was taken: When you take a picture with your phone or a present-day digital camera, that picture has EXIF data embedded in it, with the date, time, and location where the photo was taken. I’ll show you how to extract that info!
  • Editing photos: If you were assigned the task of shrinking a set of 100 photos by 25% (or any other similar basic photo editing task), you could do it manually, or you could make Python do it.
  • Creating interactive documents with Jupyter Notebook: It’s more than just a Python tool used by data scientists, Nobel Prize winners, and Netflix, but a useful programming environment and operations platform for everyday tasks!
  • Writing web applications with Flask: Just a Python makes programming much easier, the Python-powered Flask framework makes programming web applications much easier.
  • Passing interview coding tests: Learn how to deal with the most dreaded part of the interview for a programming job, and why Python is a key part of my coding interview strategy.
  • Using databases: Using databases is a key part of programming, and luckily, Python comes with a built-in database!
  • Data science: This is a giant topic and could easily take up the time to do this course three times, but I’d be happy to go over the basics.
  • Interactive storytelling and games: Python’s quite good at this, and I can walk you through the PyGame framework and Ren’Py interactive story system.
  • Mobile app development: Yes, there are ways to do mobile app development in Python.

What happens in the course?

Photo: Woman’s hands typing on Mac laptop.

This is not a passive course! This isn’t the kind of course where the instructor lectures over slides while you take notes (or pretend to take notes while surfing the web or checking your social media feeds). In this course, you’ll follow along as I write code on my screen. You’ll actively take part in the learning process, entering code, experimenting, making mistakes, correcting those mistakes, and producing working applications. You will learn by doing. At the end of each session, you’ll have a collection of little Python programs that you wrote, and which you can use as the basis for your own work.

The course will start at the most basic level by walking you through the process of downloading and installing the necessary tools to start Python programming. From there, you’ll learn the building blocks of the Python programming language:

  • Control structures that determine what your programs do,
  • Data structures to store the information that your programs act on,
  • Functions and objects to organize your code, and
  • Using libraries as building blocks for your applications.

Better still, you’ll learn how to think like a programmer. You’ll learn how to look at a goal and learn how you could write a program to meet it, and how that program could be improved or enhanced. You’ll learn skills that will serve you well as you take up other programming languages, and even learn a little bit about the inner workings of computers, operating systems, and the internet.

What will you need for the course?

Nothing fancy:

How do you sign up for the course or find out more?

Once again, you’ll want to contact Computer Coach’s Kasandra Perez at Contact Kasandra Perez at kasandra@computercoach.com or (813)-254-6459 to find out more about the course or register.

Categories
Conferences Programming What I’m Up To

I’ll be in the Auth0 booth at PyCon US 2022 this week!

PyCon US 2022, the U.S. edition of the Python conference, happens this week in Salt Lake City, Utah at the Salt Palace Convention Center — and I’m going to be at the Auth0 booth!

Come drop by the booth — we should be pretty easy to find. Just listen for the accordion.

My history with Python

Toronto programmer D’Arcy Cain was looking for a programmer to help him develop an ecommerce site for a client. At the time, the stack that web developers needed to know was LAMP — Linux, Apache, MySQL, and Perl (later expanded to include other languages whose names start with “P”). D’Arcy’s preferred stack was BSD, Apache, Postgres, and Python, which at the time was considered to be a contrarian choice.

He asked if I was willing to learn Python, and I said “Sure! I can pick it up after I get back from Burning Man, on the first day after Labor Day…”

He said “No — I need you to hit the ground running on the first day after Labor Day.”

The edition of Learning Python I used — the first edition!

And I said, “All right. I’ll make it happen.” So I packed my laptop and a copy of O’Reilly’s Learning Python and took it with me to Black Rock Desert.

Those were wild times and even wilder hair, man.

Since Burning Man is more of party-all-night place, it can be quite peaceful in the morning. The rental RV that I shared with San Francisco-based artist David Newman and our friend Nancy was an oasis of calm with a good generator, and I was able to spend a couple of hours a day going through Python exercises, catch a nap, and then strike out onto the playa in the afternoon for the next evening’s mayhem.

By the time I got back to Toronto, I was ready to start coding in Python, and a descendant of that original site and its business still exists today. I figured that any programming language you can learn at Burning Man has to be good, so I’ve been using it to get things done since then, including putting together the Tampa Bay tech events list that appears on this blog weekly.

In spite of my long-time use of Python, even during that period when Ruby was ascendant thanks to Rails, I’ve never gone to PyCon — until now. I’m looking forward to it!

Categories
Meetups Programming Tampa Bay

Building a “Wordle” function, part 1

These slides capture what we worked on Tuesday night’s “Think Like a Coder” meetup: coming up with a first attempt at a “Wordle” function. Given a guess word and a goal word, it should output a Wordle-style score.

We came up with a solution that I like to call the “close enough” algorithm. It goes through the guess word one character at a time, comparing the current guess word character with the goal word character in the same position.

When making those character-by-character comparisons, the function follows the rules:

Here’s the “close enough” algorithm, implemented in Python…

def wordle(guess_word, goal_word):
    
    # Go through the guess word one character at a time, getting...
    # 
    # 1. index: The position of the character
    # 2. character: The character at that position
    for index, character in enumerate(guess_word):
        
        # Compare the current character in the guess word
        # to the goal word character at the same position
        if character == goal_word[index]:
            # Current character in the guess word
            # matches its counterpart in the goal word
            print("green")
        elif character in goal_word:
            # Current character in the guess word
            # DOESN’T match its counterpart in the goal word,
            # but DOES appear in the goal word
            print("yellow")
        else:
            # Current character DOESN’T appear in the goal word
            print("gray")

…and here’s the JavaScript implementation:

function wordle(guessWord, goalWord) {
    
    // Go through the guess word one character at a time
    for (let index in guessWord) {
        // Compare the current character in the guess word
        // to the goal word character at the same position
        if (guessWord[index] == goalWord[index]) {
            // Current character in the guess word
            // matches its counterpart in the goal word
            console.log('green')
        } else if (goalWord.includes(guessWord[index])) {
            // Current character in the guess word
            // DOESN’T match its counterpart in the goal word,
            // but DOES appear in the goal word
            console.log('yellow')
        } else {
            // Current character DOESN’T appear in the goal word
            console.log('gray')
        }
    }
}        

I call the solution “close enough” because yellow is a special case in Wordle. If the guess word is ATOLL and the goal word is ALOFT, the first L in ATOLL should be yellow and the second should be gray because there’s only one L in ALOFT.

We didn’t settle on the “close enough” algorithm — it was just enough for that night’s session. In the next session, we’ll refine the algorithm so that it matches Wordle’s!

Want to become a better programmer? Join us at the next Think Like a Coder meetup!

Categories
Programming Reading Material

Get $411 worth of Python books for $18 with this Humble Bundle!

Once a year, Humble Bundle releases a bundle of No Starch Press’ excellent Python books, and it’s that time of year again! For the next 18 days from the time of this writing, you can get $411 worth of ebooks for as little as $18.

What you get for $1

The bundle is sold in tiers. If you pay only $1, you get this portion of the bundle, which makes for a great starter set for younger readers or if you’re thinking of getting into game development:

If these books alone for a dollar have piqued your interest, you can get them now by going to the Humble Bundle Python book page.

If a dollar is all you can spare, you’ll still be well-served by this deal. However, if you can spend a little more, the deal gets better…

What you get for $10 – $17.99

Pay between $10 and $17.99, and they’ll add these to the bundle:

In my opinion, the stand-out book in this tier is Serious Python, which cover languages features, tools, and techniques that you’ll need as you start writing applications that you or your customers will regularly use and rely upon.

If $17.99 is the most you can spare, you’re still getting a good deal, and you can go to the Humble Bundle Python book page and get your bundle now.

However, if you can part with $18 or more, you should read on…

What you get for $18 or more

And finally, if you pay $18 or more, they’ll throw in the gems of the collection:

If you’re serious about learning Python, you’ll want to pay $18 or more I used Python Crash Course and Automate the Boring Stuff with Python in the Python courses I taught last year.

Even though I bought the 2020 edition of this bundle, I bought the 2021 edition just to get Real World Python is a great way to learn some new tricks through its tour of algorithms and Python libraries. It was cheaper to buy the bundle than to buy Real World Python on its own. Do the math: You can pay $28 for Real World Python, or get all the books in the bundle for $10 less!

Beyond the Basic Stuff with Python is a great guide for writing more Pythonic code, Python One-Liners is worth it for just the NumPy and regex chapters alone, and Natural Language Processing with Python and spaCY packs an NLP course with lots of practical exercises into under 200 pages.

If the $18 bundle is what you’re looking for, go to Humble Bundle and get it while it’s still available!

The money goes to good causes

The proceeds from sales of this bundle go to:

The mission of the Python Software Foundation is to promote, protect, and advance the Python programming language, and to support and facilitate the growth of a diverse and international community of Python programmers. The majority of the PSF’s work is focused on empowering and supporting people within the Python community. The PSF has active grant programs that support sprints, conferences, meetups, user groups, and Python development efforts all over the world. In addition, the PSF underwrites and runs PyCon US, the primary Python community conference. Being part of the PSF means being part of the Python community. Recently we changed the PSF to an open membership organization, so that everyone who uses and supports Python can join.

To learn more, visit https://www.python.org/psf/membership.

The No Starch Press Foundation is an IRS 501 (c) (3) tax-exempt non-profit corporation created to support and grow the collective knowledge and contributions of the worldwide hacker community.

We support hackers of all types, regardless of experience — whether that’s the passionate beginner or the lifelong hacker wishing to make a broader contribution to the hacker community and the world.

The Foundation was formed to give back to and strengthen the hacking community. The Foundation’s founder, William Pollock, has been closely involved with the hacking community since about 1999 and much of the success of his company, No Starch Press, is due to the support of the worldwide hacking community. To date, Pollock has given over $800,000 to the Foundation and is working to expand its donor base. The Foundation’s funding will be used to help strengthen and expand the hacking community, by educating the public about hacking and working to create safe and central places for the hacking community.

Categories
Current Events Programming Tampa Bay

“Python: A Bicycle for the Mind” — 9:00 a.m. this Wednesday at the Women Who Code Tampa online meetup!

I’m talking about Python at this Wednesday’s Women Who Code Tampa online event!

This Wednesday, May 12th, from 9:00 a.m. to 10:00 a.m. Eastern (UTC-4), I’ll be in an online session where I’ll talk about using Python as a “bicycle for the mind”. I’m going to present a couple of Python tricks that I actually use to be more productive.

This session is this week’s installment of Women Who Code Tampa’s Coffee + Code, a weekly online networking event featuring a tech topic.

Here are the relevant links:

What’s this about “Bicycle for the mind”?

It’s how Steve Jobs describes computers in his appearance in a 1990 documentary film called Memory & Imagination: New Pathways to the Library of Congress.

Here’s what he said:

I think one of the things that really separates us from the high primates is that we’re tool builders. I read a study that measured the efficiency of locomotion for various species on the planet.

The condor used the least energy to move a kilometer. And, humans came in with a rather unimpressive showing, about a third of the way down the list. It was not too proud a showing for the crown of creation. So, that didn’t look so good.

But, then somebody at Scientific American had the insight to test the efficiency of locomotion for a man on a bicycle. And, a man on a bicycle, a human on a bicycle, blew the condor away, completely off the top of the charts.

And that’s what a computer is to me. What a computer is to me is it’s the most remarkable tool that we’ve ever come up with, and it’s the equivalent of a bicycle for our minds.

Categories
Programming Reading Material

Humble Bundle’s “Ultimate Python Bookshelf” bundle is available until Monday afternoon!

At the time this article was published, there are 3 days and 21 hours remaining to get Humble Bundle’s “Ultimate Python Bookshelf” bundle. Depending on how much you’re willing to spend, you can get 3, 8, or 24 books at a deeply discounted price, and some of the money goes to two worthy charities. Read on to find out more…

The books

Depending on how much you pay, you’ll get 3, 8 or 24 books.

If you pay $1 – $9.99, you get these books:

  • The Python Workshop
  • The Statistics and Calculus with Python Workshop
  • Web Development with Django

If you pay $10 – $17.99, you get the books above, along with:

  • Hands-on Exploratory Data Analysis with Python
  • Hands-on Machine Learning with scikit-learn and Scientific Python Toolkits
  • Django 3 by Example
  • Python Automation Cookbook
  • Hands-on Genetic Algorithms with Python

And if you pay $18 or more, you get all the books above, plus:

  • Python Data Cleaning Cookbook
  • Deep Reinforcement Learning with Python
  • Data Engineering with Python
  • Modern Python Cookbook
  • Applying Math with Python
  • Python Image Processing Cookbook
  • Python Feature Engineering
  • Practical Python Programming for IoT
  • Python Algorithmic Trading Cookbook
  • Applied Computational Thinking with Python
  • Hands-on Python Natural Language Processing
  • Hands-on Simulation Modeling with Python
  • Mastering Python Networking
  • Artificial Intelligence with Python
  • Python for Finance Cookbook
  • Quantum Computing with Python and IBM Quantum Experience

Interested? You can order the bundle here.

The causes

All Humble Bundles route some of each bundle’s price to one or more charities. In the case of The Ultimate Python Bookshelf bundle, there are two charities that will benefit:

Doctors Without Borders / Médécins Sans Froniteres: An international, independent medical humanitarian organization that delivers emergency aid to people affected by armed conflict, epidemics, natural and man-made disasters, and exclusion from health care in nearly 70 countries.

Stop AAPI Hate: A national coalition addressing anti-Asian racism across the U.S. The coalition was founded by the Asian Pacific Policy and Planning Council (A3PCON), Chinese for Affirmative Action (CAA) and San Francisco State University’s Asian American Studies Department. Between March 19, 2020 and February 28, 2021, Stop AAPI Hate has received 3,795 reported incidents of racism and discrimination targeting Asian Americans across the U.S..

Wait a minute — there are Packt books. Are they worth getting?

As you were reading this article, you were probably wondering about the issue of the less-than-stellar reputation of Packt’s books and if I was going to raise the issue.

Consider the issue raised, Gentle Reader.

When they were starting out, it seemed that Packt took whatever author they could get to write about the hot tech topics of the moment and rushed those books to market. Over the years, the quality of their authors, review process, and books seems to have improved. I know for a fact that Tampa-based iOS developer Craig Clayton has written some excellent books on iOS development for Packt — because I bought them all.

I decided to buy the bundle. I paid the recommended $25 for these reasons:

  • Some of the money goes to two good causes.
  • At $25 for 24 books, that’s less than $1.05 per book.
  • I’m at the point where I won’t even notice a “missing” $25.
  • I don’t consider it $25 spent, but $25 invested.

That last point requires a deeper explanation:

  • If at least a handful of these books are good and provide me with something that I can use at work, in my own programming projects, or in my articles, I will have collected a good return on my investment.
  • Even if most of them are bad, it will still be a worthwhile investment because the 25 books span a wide array of Python topics, and will give me a better idea of what I don’t know, and better still, what I don’t know I don’t know. I can then look for better sources of information.

As I go through each of these books, I’ll post my findings and opinions here.

How to order the bundle

Once again, Humble Bundle’s “Ultimate Python Bookshelf” bundle is available until Monday, April 26 at 2:00 p.m. EDT (UTC-4). If you wanted to learn Python, sharpen your Python skills, or expand your knowledge of where you can apply Python, this bundle is worth considering.