16. How do we pick programming languages?

16.1. Admin

  • make sure you have a PR open for any work you have not received feedback on

16.1.1. What is a pull request ?

like what say you were working on something you made some changes and then

you merge before class but then you made new changes on that Branch then you can make a Newport I sent the request from that bridge is closed but you have to it like

you can always do that right so you have to just keep things kind of separate so until it branches merged you can’t make an additional per request from it because it’s it’s like

but it’s not like a part of us isn’t the thing that exists inside repository right branches exist inside their policies when you download with get clone like I’m working out so you can see all the branches you have but the poor West isn’t there the poor of us is just

it’s like a helper for a person to do it once a mergency branches or merge this one into the other like we talked about get work clothes right and there was like an iteration manager version on so get its actual Source forget itself

is actually mirrored on

right to have an organization the mirror that store still here but this is just a publish only depository that they don’t actually use pull requests to hear people don’t follow instructions and make them but they don’t actually use the four of us to decide what it says yet to submit which of these approaches to the mailing list so if you want to submit a pull request to submit changes to the get source code that actually have an email

yes I do know there’s that’s their way of kind of limiting who’s going to do it and who’s changes are going to consider seriously because get invented like GitHub cannot exist until so get predates GitHub

16.2. IDE Review

so last week I had you read about IDEs is it going to see will come back in touch and reinforce some of those things in different classes of you talk about how like what actually happens to code cuz that’s what’s going to happen to the rest of the month or so the first part we talked a lot about the tools we use

but we we just been playing with text files because they’re easy and they can do we can treat them just like weird code files what

happens with a code when you bought it starting from like how does comp compilation work all the way down to

like how our numbers are presented in computers machine representation. so

Wii U read about ideas but let’s just a quick review to make sure they’re paying attention and you’re awake and here so first question or piss me off just what is it stand for

16.2.1. What does IDE stand for?

Integrated Development Environment

16.2.2. Why do we use them?

To keep all of the tools together, increase ease of using multiple together.

Also provide additional features when it’s a development focused environment:

  • easier path handling in terminal

  • developer friendly features in text editor (mulitple cursors; copy+ paste at once; tab completion; syntax checking )

  • having to file explorer panel while you’re looking at your code helps you see what’s going on and see for example a function definition at the same time as where you’re calling it.

The More practice from last week is expected to be a longer one.

yeah right if it combines two things are copy and paste and do just one thing

well right. Really sophisticated phone replaced if I can see mine is here

this is what I was doing when I was editing notes after class cuz my nose when I export them have like the it has electronic don’t like the brown there I’m at whatever for my criminals I don’t take that other line but you can also

16.3. How can we compare Different Programming Languages

matter they very what are they share what sort of a structure a level not like any specific language in detail but like what is it what do you think about your choosing a program or you’re trying to understand what happens cuz we need to think about this talk a little bit to set the stage for what happens in a in a specific case of how do we go from high-level code that’s read of relative. What you don’t see might be a little at the lower-level still have a really good but it’s lower than that to the zeros and ones that are computers going to run out eventually

so let’s start brainstorming and what are some different things you could use to compare

  • Garbage collection

if you stop using something or you you don’t need it anymore does it keep using resources until you manully, in your code tells it okay it’s not that bad or does your the language know to okay this is we’re done using this let’s stop what’s another thing

  • static vs dynamic typing and memory allocation

number yeah so can you change the type of a variable on the fly or do you have to Define it like you to declare what type of variable is going to be so that it can allocate the memory in the right format for that variable and then it’s stuck is that type you can’t change it until you unless you re initiating are you can’t it’s not going to be there what else Christian

  • syntax

white space use syntax specifically other like what type of bracket to use what types of whatever you use and I tried to add more things to my list and instead I sent it so now my list is there but we can keep going what are you doing

  • programming Paradigm

whether you’re focusing on like everything has to be declared as an object whether it’s just like you have some functions and some scripting type things do some programming that support sort of really sophisticated data mapping structures or language is coming with you. I like python you can do however you want like it has a lot of functional features it has object-oriented it can find a support doing a lot of the different things in Python is added more functional feature support right there making it more supportive of those actions because they’re they’re powerful and they’re really good for the type of thing to do would like to use Python for what else

16.4. how do you decided to pick one language vs another?

  • API support to access necessary resources/hardware

  • specialization of the language (some are built for specific purposes)

yeah so why don’t you talk about so far have been really technical details like does it actually do the thing you wanted to do but there’s also could be easier to learn the new language or there’s also star in community aspects are the amount of users of language so there’s a language called Julia that I think it came out like in like late 2010 2011 is somewhere around there maybe even a little bit later it was very very very powerful to do the types of research like the types of work that I was doing my butt is very very new so didn’t have a lot of documentation it didn’t have a lot of people using it

even though it was like quite appealing for a lot of things I was going to do it would have been more performance they were doing better before his life than python I will not let that up to that I ended up using I just not usually up because there are no libraries like I was going to implement basic things that I did not have to implement in Python because I could use libraries and python

1/2

what

actually do that with the Limitless

is that is having her list that is that is about choice so I’m going to

have you review this developer survey after I send I want you to read through for a couple minutes and pick the one thing you most you find most interesting you want to discuss and I will be right back

all right what is the most interesting thing you found on this Saturday

going to wait till someone else that has not spoken yet wants this week I’ll get to the three of you but Tyler

looking for

that was really not that bad

so it’s good that you’re not loud is what it’s supposed to be used for if you’re doing linear algebra nothing else like all the rest of these are terrible but yes so there could be some explanations are what else

45% Windows users I don’t know what text what section are they in

are there that’s okay yeah a lot of surprising

you don’t know

to the equal when it’s Mason. OS a very small percentage of people using this what album is this what if we switch from all respondents to professional golfers it’s all just a little bit to get more math less less than a Caesars

and this is still 57,000 people so it’s not like a smaller number but not his number this is still what

most corporations is just what they give you if you work at a big Corporate Place like that’s what they give you so you’re not really this is really getting to choose so even though like and I could be me and you won’t see as much people do people sell Windows 7 starter it’s still realistic like that’s what people get also if you want your stuff to run on Windows you have to make it work there

there has to be some amount of thought this Sabrina

yeah so it’s been for a long time most loud but people actually using it as is smaller yeah some people that use it love it also if we will get people that want to use it it’s still pretty high right through the do not use it but wish they could like would like to you so pretty high

Christian

send the next question

I’m just trying to find it so yeah this is this is a good thing obviously this was a good thing for us to be learning cuz don’t have a version of the schedule and get is by far the most everyone using it of the respond to the survey this is so this is which is students as well

especially about the same does it mean when I smile doctors

sounds like a very hyper standardized it’s kind of like a virtual machine almost so I’m guessing more of your views

so, basically

avocado pie what when you use it so

let’s say you’re doing with the reason the way I come into contact with people who are doing who produce the project maybe they designs project they use a whole bunch of libraries a whole bunch of installed that got everything working and then they want someone else to be able to use it to how many times have you set up a programming environment and there’s a lot of insulation possibly as much insulation is trying to use the place actually build your thing at all

Rite insulation give me really hard and really annoying so doctor makes that easy to the doctor container specifies all of the requirements and stuff them all up it also allows you to have some multiple containers on your computer so you can have one environment for doing this project another event for doing a project that don’t interact with each other and to doctors like a standard and a technology to help support that

badass more than 100

yeah so that the people could check more than one so it’s just like

they allowed people to check as many as they want and they could even check both of they use it and they want to use Technologies

these are computers just like these are the most popular things at all communities is another like platform tool for like spitting things out separately I think he’s going to take a package I think it’s a package manager as well I have a feeling it might be related to

are or like publishing but clearly not crapping

yeah and install it’s idiot Auntie I’m so it’s a Java Java Java I forgot those 10 I don’t either then when I choose to do so but it allows you to packaging and what else

you can get paid to go to school

oh yeah if you like probably like it so if you’re like a managing service systems also we have a bunch of a do those kind of things different trying to hire someone who’s going to manage their servers they’ll be doing other things but only programming are probably doing it on his way back type things

I cannot this family was supposed to be there but the faster you don’t know about it it’s probably directly related to why it pays higher cuz things that people don’t know get paid more

yeah

and then things on there so this is an artifact of a large percentage of people doing this or grad students

once you’ve done enough times with no longer that little crisis here at this is just what it is we truncate the list

eventually so we don’t put every possible cuz out of 80 thousand people I’m sure unless it was other things arranged thing

why is it useful to read through these results why is it something that is worth spending time on a glass Tyler

yep he’s a home from other developers you get to know kind of what’s out there

yeah if you’re trying to decide what things you want to run outside of time that’s important also knowing kind of how different programming languages compared we saw we saw a list of Unforgiven images Nancy hadn’t heard of the four of us out there and if you don’t know it in great detail helps you kind of get the landscape of what’s out there and how different things are changing and how they interact with another also this sets the stage for the fact that we’re not talking about things that are just like cuz I feel like it

or like giving things are actually important that that are used in industry and that are that are useful so

it was another question so if you go back to that list of

difference things we can compare foreign languages on we’re trying to start thinking about using a project

how

what would your first step be if you were trying to pick what language to use for new project

figure out what your needs are for you what’s there

writing a what labor jobs

so when

but for example

if we talked about a linkage being compiled versus interpreted so a compiled language you write your code you hand it over to compiler and then it gets a machine code I’m about 100 over and over again and interpreted language you write your coat and head to The Interpreter The Interpreter runs and gives you the results back you can run one line at a time you can kind of you but each time you want to run it it’s doing any work that’s compilation like sort of on the flight as you run it right

when would you want one or the other

okay so

which one of those like if you so you’re saying whether the data that the program is going to use is going to be variable you might want to choose

okay so what’s on tap at typing with python although it is and then there’s static typing which see Elsa is but separate from that she has compiled do it like you get a bill to do that and then python is interpreted so you give him the code of The Interpreter and it runs right one at a time either of those could actually handle a large amount of data or variable size data right cuz you can

always

like Rita file and get the information then allocate besides that’s not going to change that but would be different

indeed.com

python

I don’t know what it is

oh oh cuz you can’t like use a class object inside of a class definition okay

yeah

okay so that would be a case for if you need to make kind of that type of nothing but a compiled language can do that but interpreted

I didn’t cannot that’s good example okay what else would you want one with the other compiled verse Jeopardy Sabrina

so if you mean something resource-intensive you want to be compiled so if you’re reading something that’s going to run like on a small device like a Fitbit or a smartwatch write those don’t have a lot of memory didn’t have a lot of things he’s going to find out where do I have a person I know who works at

did he propose in libraries part of NASA her job for awhile was too during the 17-minute window that happens twice a day send code to the Mars rover they can’t send pythons are there right they can’t let you know the river is is very far away that was 70 minute window to transmit things over a slow satellite link they have like KB a day they can send

price of a need cuz it’s going to compress down to the thing also the how long ago to the Rover leave Earth I don’t know if you know but as long as you know the actual time

great it’s been gone for a long time so Hardware that we have now is very different than what was available and able to end amount of time before it actually left is what it was designed

so the hardware that has is very old for a computer hardware so they’re very stress and strain but they’re still want to like do scientific data analysis on another planet which is when

oh okay yeah there’s everyone has been gone for a while

okay the last time I talk to this person was an in-person conference which was definitely in 2019 or early 2018 so

okay

I thought everything was old has a very resources and environment they still need to be able to do real things right it’s not a toy problem is not a we’re just playing with an Arduino because we feel like it it’s a real thing right it’s a real real where they had actual Hardware constraints they had to have very a pin code to decide how to collect the data and then how to get it back they know that 17 minute window to happen twice a day they can send its also receive other data back about her experiments in that time but if you really want to send and want to get data back

so we had to have really efficient code to get in the house so we’ve got some cases for when you would want them piled what made you want interpreted language

when does it become better for you

I mean you have to have you might have to have that but what would what would give you the advantage out of it

you’re saying

you have to do is lovely all right cuz you don’t to wait for it to compile and when would you why would you not want to wait for some pile you need to physically Tyler

program

yeah so with four examples for every type of Hardware that you want to run on right but interpreted language

someone has to make The Interpreter compiled for every single part where you want to run on but you the developer that language don’t have to make your hair different right there’s a few things for gambling python you can’t use you can’t hardcore pads with boards lashes because Windows use the other / but other than that you can run your code on everything you want your language help you out a lot

and you have made changes and I looked and test it and you’re going to it’s going to be a lot harder to take a little while tomorrow and you put her in it

yeah when you’re experimenting or take ring or the reason I use Python is that you did an outfit I need to I don’t know what the third step is going to be in till I see the results on the 2nd

so I need to run over s up get the results and then decide what to do next cuz I’m looking at the data processing and I’m calculating deciding what to do next so since I can’t plan on my advance

compiled language doesn’t make sense right

Oso

Sophia pass in San Antonio not Windows uses for it in Windows uses backsplashes and pads so you have to not talk with your path and python dissolution is there’s a library called OS and you use OS taco joint

that join to put them together instead of typing the splashes because that it makes it Go your problems go away that is a problem that I learned through a lot of pain and suffering so isn’t that I know well

what else am I to you

or any other reasons you might want to choose interpreted first compiled

all right so if you were complaining that you would want to use which kind interpret it right cuz you’re trying to see if the thing can work you just want to get a really good result and you’re not trying to package it up into everywhere

another case for when people would prefer compiled languages is if you want your source code to be private if you don’t want to distribute your source code you have to use a compiled language I got to give it compiled down to the binaries and distribute the binaries right

that’s my knowledge now

you can like

I’m just kidding I think but I don’t think like is actually private

what you cannot see the code the source code to recover the source code from the banners I mean you can’t recover it precisely because like you could write code lots of different ways that results in the same binary straight like you could write an arbitrary number of different thing that got to the same thing

there’s a certain amount of you can like

pack together things but it’s not true it’s not trivial and not easy I believe that’s a thing that like a certain type of researcher like attempted to do but it’s not something I ever has drama divisions to do

so becomes really really hard to trace out the Kodak Center like recover at a high-level from the binary is because everything is compiled down in Pacific cases

right so yeah it is very good but you might be able to cover a certain amount of it

I know there’s like Steps intermediate steps that that can help cuz like I had

a friend who was

Miss Universe that are working with a professor to help right auto traders because I thought my situation is a thousand students and their and their horses so I think they were doing what they want the cluster student Solutions in group all the teams that made the same mistake together so they could send the same advices is it doesn’t seem the same as they were doing sort of like partial compilation to the who record you could tell when seems like even if they use different variable names they can if they have the same sort of bad structure in their Loop or whatever you can tell so there’s things that you can do with different languages depending on what it is but that’s not

generally easy or like a common thing to do

yeah so people that people do try to prove sort of like that things are the same or equivalent or like comparable to the stop now you’re right up the front of the edge of like state-of-the-art kinds of things

Okay so

we talked about what’s it like to build and run the environment

we’ve been to the garbage collection how hard do I tell if it is is a programming language the typing of the static or dynamic availability of like libraries in apis and excessive has access to whatever it is you’re trying to enter access

and I touched down briefly but there could be this this factor of Life Community amount of user so other people like how do you actually get help for that language can you understand it like is it written in your human spoken language right some languages have some programming languages have documentation in a lot of different human spoken languages so I’m only in English so if you don’t speak English well you can’t use of languages

Okay so now that we’ve

talk about this a little bit let’s go through something else so

you

we’re going to do a project with

robotics what would you look for in an English

what kinds of things do you look for what would you want it to be like

the speed that needs will run fast on whatever the hardware the robot has cuz your robot may or may not have a powerful like computer or a lot of memory depending on the size and location is going to go

does he like does it have instructions that support the library or Library support like did the people that build that robot give you an API I’d like that to control it

it was a day when you’d like a compiled language you can give the results you give the robot the program you just let it go you don’t want to be interacting with the robot sort of like one step at a time necessarily you might want to be able to do that sometimes but really most the time you want to let it go usually

probably able to make me to delete data so you want a language it’s not going to like have a lot of bugs cuz you don’t want someone accidentally like inserting code and like a feeling you’re about to go do bad things that you didn’t like to do you want to interact with any data that the robot is using

what about

what kind of language is you think people might use what types of what examples of languages.

Christian

and I think I thought would be good for that because I’ve heard that it’s just like just the kind of thing and also it’s easy to like them since August atticly type of language

okay so if your robot was going to do the day that I was just like in the field you might want to use Python what other cuz we talked about it you might want something that’s going to be fast and packed I have good libraries for the robots itself what other languages you think you might use with a iRobot

Rikers Island so

its popularity has recent so the disadvantage of the reason I may not work is cuz the the hardware for the robot may not have support for rust

why

but it also

Boulder so compiled languages both good for that CD holders, in another sneaky language in common robotics because

not loud is not open source Wright was willing to do you talk about open source are developed by community of whoever else whatever Matt love is not / coming to go math works and MathWorks works very closely with Hardware manufacturers to make sure that Matlab can work with your Hardware because I want the Dave want people to pay to use their language so they work with people who sell expensive things to make their expensive things compatible with their language

rights to these other kinds of artifacts like a lot of Engineers use Matlab because all of their like different things you plug in that work really well with that right I speak cameras will have an API with Matlab all of these kind of hard because it’s like we want to get people to use our language so they lock people into or what will make it easier for you cuz it’s going to be easier than C

right it’s maybe not as nice as like python but it’s going to be way easier than see if you would want to buy that will go up that way to get these weird

MathWorks the company

I mean they can’t they can’t prevent that in that sounds like it’s any damn sure is there and in fact you can actually it’s relatively easy to integrate Matlab code whiskey cuz also most other thing a lot of other things are like written with the your compatibility so you’ll start to see what a big project actually have multiple project multiple languages involved

Wright’s like one of my club jobs I was doing signal processing I was like doing like real time radio stuff so to make the real time part work I had to use could I would you like Siri but for the early for gpus so to write the code to paralyze my functions cuz this was 2010 and no one has written libraries it did that for you and then the main part of the analysis and not lie but I was hoping to be in my life cuz I was working with you is awesome cleaner doing because if you have a really big project just probably going to be different parts of it that different languages are going to be better for and so sometimes it’s not worth sacrificing one part for the other part you just right in both languages and select the data back and forth

like other examples are

python is way better at doing like date analysis calculations and like JavaScript write like you don’t want to do a lot of math

browser than python you also don’t want to like right to be 75 on like no one wants to do that so there’s whole framework take data from the browser give it the python get the results back from Python and put them in the browser so they run little web servers just to do that right there makes passing back and forth so you can write in the most the best language for the specific tasks in your project and then he’s like packages I’ll help you tie it all together to make it work so

was he a machine-learning that’s good

so

we’re talking about doing

data analysis with python code on because I wanted to do another language really, information on and get as far as the language made by statisticians for statisticians right so

I don’t know why someone would want to choose if you’re doing something to get analysis when you might want to use Python A R

Library

just talked to your comment and it will calculate you even like my normal distribution table something else cuz it’s too many things like specific first a decision that very very pretty close to fix the article will be like half as many lines even in Python with them because I was more powerful things are in Python but if you’re trying to do like if you’re an ecologist or a biologist try to do that goes those comments at 264 them to me way better does a port there then you get the snacks level where because most likely I’ll just call just that her up use are when they develop new techniques novel data analysis techniques there specific strategies for analyzing genetic data for example

they’re going to use our to do it they’re going to release it as an AR Library do you start having used a virgin Obviously good the specific type of thing you’re doing is going to be between which one you’re going to use some kind of understanding what the community is and who likes that language often becomes useful and so beaver not that super think technical details we tend to talk about but they’re really important things to know about languages and understand so

we will start wrapping up now

one thing you learn today

and 1 questions have you do something your cares about or something you wanted you want Clarity on

see a quick question about internal pandas is a library in Python and it’s sort of an acronym

but it’s

data analyst for data analysis so

the main thing that pandas does is a python you have like other data types right you have lists and pandas gives you a dataframe or like a table

all the data structure is amazing provides and then all of the methods to do like a lot of basic analysis and plotting so they supposed to just fix I’m plotting and all of those kinds of things like on your I’m grabbing a little about a lot of things it’s not so easy to read and write that people don’t care that it’s actually like very slow because like human time is way more valuable than her time computers have a lot of time people know

ready like undo a part of a carrot yeah actually time to do that actually I had to do it on my device like I do it locally and then push to go and back

I was working on something but the fire was like over 100 MB and I skip up because you can’t put that yeah

16.5. Prepare for next class

  1. For 2 languages from the loved vs dreaded list (one top 5; one bottom 5) read 2-3 posts about why people love/hate that language and summaries the key points on each side. Add this to your kwl repo in language_love_dread.md

  2. Make sure that you have a C compiler installed on your computer. ideally gcc

16.6. More Practice

  1. (priority) 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.

  2. Try out/learn about one of the following languages that you have not used before, do something small that is typical of that language (eg a toy data analysis in R or ): R, Julia, Clojure, Stan, Go, . Answer the following questions:

    1. What is this language designed for?
    1. What Progrmaming paradigm(s) does it support?
    1. What about it makes it easy to learn for someone who already knows some other language (name that language)?
    1. What about it is hard to larn for (pick a language) prgorammers?
    1. What is its most unique feature(s)?
    

16.7. Questions After class

16.7.1. What is pandas?

pandas is python data analysis library

16.7.2. How do you implement programs/projects which depend on multiple languages, like a web browser that uses javascript but does calculations in python.

You keep all of the files together and set up build tools to build as needed

16.7.3. Where might one person go to find out which programming languages is best for their project? Is it through personal research?

It is through learning about through networking and keeping up with trends. It’s also through trying new things. As you know more, you build intuition about what to do and sometimes just talking to others.

16.7.4. Are the languages used for classes arbitrarily chosen or is there a process that the professor goes through when picking the language for a class?

We, as faculty choose together a lot actually, based on the concepts we want to teach and what language features that requires.

We also keep up to date with CS Education literature which studies how different languages impact learning.

16.7.5. What kind of non technical questions should I be asking when developing?

This is a great question, but beyond the scope of this course to cover it entirely. CSC 320 would help give you more ideas and context for this.