# Allison Kaptur

In early October I gave a keynote at Python Brasil in Belo Horizonte. Here is an aspirational and lightly edited transcript of the talk. There is ...

This is one page of public article previews, not the complete archive. Follow Next page to continue. Summaries are not the original full articles.

## Effective Learning Strategies for Programmers

DevFeed: [Effective Learning Strategies for Programmers](<https://devfeed.tech/articles/effective-learning-strategies-for-programmers-29448.md>)

Original publisher: [Read original article](<http://akaptur.github.com/blog/2015/10/10/effective-learning-strategies-for-programmers/>)

Published: 2015-10-10T22:15:00Z

Content type: article

Language: en

Sources: [Allison Kaptur](<https://devfeed.tech/sources/allison-kaptur.md>)

Topics: [Learning](<https://devfeed.tech/topics/learning.md>), [Programming](<https://devfeed.tech/topics/programming.md>)

Tags: [effective](<https://devfeed.tech/tags/effective.md>), [learning](<https://devfeed.tech/tags/learning.md>), [programming](<https://devfeed.tech/tags/programming.md>), [research](<https://devfeed.tech/tags/research.md>), [skills](<https://devfeed.tech/tags/skills.md>), [strategies](<https://devfeed.tech/tags/strategies.md>)

### AI overview

An article about effective learning for programmers, presented as an edited transcript of a Kiwi PyCon keynote. It introduces mindset and learning strategies, drawing on experiences at the Recurse Center and research on effective learning.

### Source excerpt

In early September I gave a keynote at Kiwi PyCon in New Zealand on effective learning for programmers. There were two pieces to the talk: one about mindset, and one about particular strategies we can use. The text below is an aspirational and lightly edited transcript of the mindset piece of that talk. There's also a video available if you'd like to see the strategies piece. Recurse Center Before I joined Dropbox last year, I spent two years working at a company in NYC called the Recurse Center. The Recurse Center is like a writers' retreat for programmers. Participants spend 3 months working on whatever is most interesting to them. So someone who'd been writing Java for ten years might come to RC to learn a new language like Clojure, or someone who just graduated with a CS degree might come work on their web development skills, or someone who'd been learning programming in their spare time might come to turbo-charge their learning. There's almost no structure to the program - no deadlines, no assignments, no teaching. It's an experiment in unstructured learning for adults. My role as a facilitator was to help people make the most of that disorienting amount of freedom that they had at RC. People who come out of traditional educational experiences or traditional jobs very often don't know what to do with that. So I'd help them with goal-setting and help them make the most of the experience. One of the things we thought a lot about was how to have the most effective learning experience possible for programmers. Today I'll talk about some of the research into how to be an effective learner, and how we can apply that research to our daily lives as programmers and engineers. What to get out of this post Take a minute and consider what you'd like to get out of this post. You might want to learn something new about how to be as efficient and effective in your job as possible. You might want to hear about how you can be a better teacher or mentor to junior engineers. Or y

## PS1 for Python3

DevFeed: [PS1 for Python3](<https://devfeed.tech/articles/ps1-for-python3-29447.md>)

Original publisher: [Read original article](<http://akaptur.github.com/blog/2014/10/23/ps1-for-python3/>)

Published: 2014-10-23T21:38:00Z

Content type: tutorial

Language: en

Sources: [Allison Kaptur](<https://devfeed.tech/sources/allison-kaptur.md>)

Topics: [Python](<https://devfeed.tech/topics/python.md>), [version](<https://devfeed.tech/topics/version.md>), [syntax](<https://devfeed.tech/topics/syntax.md>), [function](<https://devfeed.tech/topics/function.md>), [export](<https://devfeed.tech/topics/export.md>), [file](<https://devfeed.tech/topics/file.md>), [import](<https://devfeed.tech/topics/import.md>)

Tags: [export](<https://devfeed.tech/tags/export.md>), [file](<https://devfeed.tech/tags/file.md>), [function](<https://devfeed.tech/tags/function.md>), [import](<https://devfeed.tech/tags/import.md>), [python](<https://devfeed.tech/tags/python.md>), [syntax](<https://devfeed.tech/tags/syntax.md>), [version](<https://devfeed.tech/tags/version.md>)

### AI overview

A Python developer explains how to customize the interactive prompt with PYTHONSTARTUP so it clearly indicates whether a session is running Python 2 or Python 3. The article also shows how to use print_function from __future__ to adopt Python 3-style print syntax in Python 2.

### Source excerpt

I spend a lot of time flipping back and forth between Python 2.x and 3.x: I use different versions for different projects, talk to people about different versions, explore differences between the two, and paste the output of REPL sessions into chat windows. I also like to keep long-running REPL sessions. These two activities in combination became quite confusing, and I'd often forget which version I was using. 1 2 3 4 5 6 >>> print some_var File "<stdin>", line 1 print some_var ^ SyntaxError: invalid syntax >>> # *swears* After the hundredth time I made this mistake, I decided to modify my prompt to make it always obvious which version was which, even in long-running REPL sessions. You can do this by creating a file to be run when Python starts up. Add this line to your .bashrc: 1 export PYTHONSTARTUP=~/mystartupscript.py Then in mystartupscript.py: mystartupscript.py 1 2 3 4 import sys if sys.version_info.major == 3: sys.ps1 = "PY3 >>> " sys.ps2 = "PY3 ... " This makes it obvious when you're about to slip up: 1 2 3 PY3 >>> for value in giant_collection: PY3 ... print(value) PY3 ... I've also add this line to mystartupscript.py to bite the bullet and start using print as a function everywhere: mystartupscript.py 1 from __future__ import print_function This has no effect in Python3.x, but will move 2.x to the new syntax.