23. How do I choose a Programming Language for a project?#
Today we’ll explore how programming languages are cateogrized. Along the way, this will expose what core, generic features of a programming language are.
The key takeaway that I want for your is to have intution for how to choose a language for a project, not only your favorite, but what is the best for different types of projects.
Tip
You should do either the in groups
(if in class) or the on your own
sections below for the x.x.x. For the x.x sections do all of them.
Important
Use the makeup workflow with an ISO formated date (YYYY-MM-DD)) if you work asynchronously. If in class you can do a regular experience badge.
23.1. Comparing languages you know#
Tak a few minutes on your own to fill in the follwing table for two languages of your choice. Replace the <langugage>
with two languages that you are familiar with. Add two additional rows. You can do this by memory, or by looking up/discussing. If you look things up, be sure to use reputable sources and include links to them.
In class you can work on this on a whiteboard or on your computer.
| feature | <language1> | <language2> |
| ++++++-- | ++++++-- | ++++++-- |
| use of whitespace | Text | Text |
| list/array types | | |
| variable typing | | |
| memory usage | | |
23.1.1. In groups#
Share your table with some classmates and then discuss how they are similar and different.
Together, produce a list of questions for what other things you would want to know about how programming languages compare. All of you should include the collaboratively developed list in your experience report.
23.1.2. On your own#
Think of a few questions about how you might compare programming languages.
Try to find high quality answers for them, from reputable sources. You can use an AI to find preliminary answers, but you need to find high quality sources to fact check and make sure you do not confuse yourself with incorrect information from a chatbot
23.2. Learn more#
Read the following
What is the study of programming languages? intro to PL
23.2.1. In groups#
You can divde the sources up and then discuss.
Discuss the readings, in particular:
what you found most interesting
was anything new to you?
what do you want to remember most or learn more about?
23.2.2. On your own#
Add notes on broader patterns below your table in your experience report based on reading the sources above.
Answer each of the following questions with specific references to the readings:
what you found most interesting
was anything new to you?
what do you want to remember most
what do you want to learn more about?
23.3. PL in Developer Survey#
Resources:
the most recent developer survey// languages section
Additional reading about the languages from their official references if needed to answer the following questions.
23.3.1. With classmates#
First discuss your prepare work then go back to the survey results to find more information and answer the following.
Discuss the findings to answer the following questions. This discussion should be at least 10-15 minutes including looking up information about different languages. As a group, you may divide and conquer this research.
what is surprising?
what did you expect?
what do the popular languages have in common?
what do the dreaded languages have in common?
How are popular vs dreaded languages different? What features might be the cause for making a language dreaded?
How to used languages differ from less commonly used languages? What features might be the cause for making a languge popular?
How have things changed since 2011?
Include (shared) notes from the discussion in your experience report. Reflect (individually) on a few key points (2-3 bullet points) from the discussion in your experience report for today.
23.3.2. On your own#
Include answers to the following questions in your experience report for today.
what is surprising?
what did you expect?
what do the popular languages have in common?
what do the dreaded languages have in common?
How are popular vs dreaded languages different? What features might be the cause for making a language dreaded?
How to used languages differ from less commonly used languages? What features might be the cause for making a languge popular?
How have things changed since 2011?
Reflect on how you might use this information when deciding what language to learn next based on this information.
23.4. Prepare for Next Class#
Enjoy your break. Get some rest.
(this is just here to not break scripts, no prepare work)
23.5. Badges#
Choose two languages from the desired admired list. THis could be a highly admired and least desired; it could be one with a small gap and one with a large gap. Read a few posts about each language and try to figure out why it is/not admired or desired. Summarize your findings. Include links to all of the posts you read in a section titled
## Sources
in your markdown file. For each source, make a bulleted list with some notes about the author’s background and any limitations that might put on the scope of their opinions. (for example, a data scientists’s opinion on languages is very valuable for data science, but less for app development) Add this to your kwl repo inlanguage_love_dread.md
.
Describe a type of project where it would be worth it for you to learn a language you have never used before in newlanguage.md This should be based in what types of features for the language your project would require and/or what would contribute to the long term health of the project. Your justifiction must come from sources used in class and be based in factual evidence about the language.
Learn about one of the following languages that you have not used before: R, Julia, Clojure, Zig, Go, erlang, Elixir or another language you are curious about that appeared in the Developer survey. For example you might be interest in the top paying languages. Use the official documentation. Answer the following questions in languagelearning.md:
1. What is this language designed for? 2. What Programming paradigm(s) does it support? 3. Give at least 1 example of a programming language that experience in would make it **easy** to learn this language and explain why. 4. Give at least 1 example of a programming language that experience in would make it **hard** to learn this language and explain why. 5. What is its most unique feature(s)?
hint: for questions 3 & 4, for example learning Python first does not make it easy to learn C++, but learning C makes it very easy to learn C++ (but I have not filled in explanations).
Explore badge option
Actually try out one of the langauges above in a new repo created from this asssignment.
work on a branch and commit after each step
Setup the devcontainer to provide the compiler/interpreter for the language of your choice. See features
Add top extensions related to the language to the devcontainer.
Add a gitignore file for that language
Write a hello world type program in the language and make sure it runs.
Use the official documentation to figure out a common task in the language and write an example program that completes something typical for that language (eg a sort data analysis in R). You may use GitHub Co-pilot in the code space to help write the code, but you should justify the task you ask it to do. Commit any generated code immediately with the message “code from copilot via
” and your prompt filled in. Test your understanding of the code by trying to modify it, and make commits describing what you changed and why.
Fill in the prompts in the README (follow the comments) and Answer the questions in the README of the template repo.