The Language of Programming

The Language of Programming

Humans use language to communicate with one another; humans use programming to communicate with machines (or do they?). In this talk we’ll look at the practice and culture of programming from the perspective of linguistics, the scientific study of the form, meaning, and function of language. We’ll explore what lessons we as programmers can learn from subfields as varied as grammar theory, language acquisition, psycholinguistics and sociolinguistics.

(Presented at Deconstruct 2018, GOTO Chicago 2019)

654527a5cff1756177ef0b1bb0af7aa3?s=128

Anjana Sofia Vakil

May 22, 2018
Tweet

Transcript

  1. The Language of Programming @AnjanaVakil

  2. @AnjanaVakil what is code?

  3. @AnjanaVakil language

  4. @AnjanaVakil language for machines?

  5. @AnjanaVakil language for machines?

  6. @AnjanaVakil language for machines?

  7. @AnjanaVakil “a computer language is not just a way of

    getting a computer to perform operations…” -Structure & Interpretation of Computer Programs
  8. @AnjanaVakil “…it is a novel formal medium for expressing ideas

    about methodology.” -Structure & Interpretation of Computer Programs
  9. @AnjanaVakil “Thus, programs must be written for people to read,

    and only incidentally for machines to execute.” -Structure & Interpretation of Computer Programs
  10. @AnjanaVakil language for machines? humans

  11. @AnjanaVakil it's all about collaboration

  12. @AnjanaVakil language is power

  13. @AnjanaVakil language with many faces

  14. @AnjanaVakil every language matters

  15. @AnjanaVakil every language matters Gender distinctions in Independent Personal Pronouns

  16. @AnjanaVakil deconstructing language

  17. @AnjanaVakil deconstructing language

  18. @AnjanaVakil deconstructing language texts words syllables phrases morphemes phones turns

    sentences phonemes …etc
  19. @AnjanaVakil deconstructing programs modules expressions statements types lines bytes functions

    objects instructions …etc
  20. @AnjanaVakil “There are no theory-neutral structures in linguistics.” -Michael Tomasello,

    Linguist
  21. @AnjanaVakil deconstructing paradigms

  22. @AnjanaVakil “Each paradigm supports a set of concepts that make

    it the best for a certain kind of problem.” -Peter van Roy, Computer Scientist
  23. @AnjanaVakil prescriptivism

  24. @AnjanaVakil prescriptivism “FORTRAN [is an] ‘infantile disorder’” “BASIC [coders are]

    ‘mentally mutilated’” “COBOL … cripples the mind” “APL is a mistake” -Edsger Dijkstra, Curmudgeon
  25. @AnjanaVakil prescriptivism “FORTRAN [is an] ‘infantile disorder’” “BASIC [coders are]

    ‘mentally mutilated’” “COBOL … cripples the mind” “APL is a mistake” -Edsger Dijkstra, Curmudgeon NOPE
  26. @AnjanaVakil APL ain't no mistake

  27. @AnjanaVakil APL ain't no mistake life←{↑1 ⍵∨.∧3 4=+/,¯1 0 1∘.⊖¯1

    0 1∘.⌽⊂⍵}
  28. @AnjanaVakil APL ain't no mistake life←{↑1 ⍵∨.∧3 4=+/,¯1 0 1∘.⊖¯1

    0 1∘.⌽⊂⍵} Conway's Game of Life in Dyalog APL
  29. @AnjanaVakil APL ain't no mistake MATLAB®

  30. @AnjanaVakil APL ain't no mistake

  31. @AnjanaVakil “Languages are cultural artifacts that differ radically among different

    cultures, and languages change in important ways as the communicative needs of their speakers evolve over time.” -Michael Tomasello, Linguist
  32. @AnjanaVakil language in context

  33. @AnjanaVakil language

  34. @AnjanaVakil gender nationality power family status oppression politics religion economics

    race language
  35. @AnjanaVakil gender nationality power family status oppression politics -------- religion

    economics ---- --- race -------- - ----- ---- ------ -- - language
  36. @AnjanaVakil gender nationality power family status oppression politics -------- religion

    economics ---- --- race -------- - ----- ---- ------ -- - code
  37. @AnjanaVakil words are actions

  38. @AnjanaVakil words are actions

  39. @AnjanaVakil words are actions s/whitelist/safelist s/blacklist/blocklist s/master/leader s/slave/follower

  40. @AnjanaVakil “If we're going to teach programming around the world,

    we have to be aware of what the cultural biases are.” -Ramsey Nasser, Creator of بﻠﻗ
  41. @AnjanaVakil teaching in context Noor: a beginner-friendly Arabic programming language

    by Ahmed Abdalla github.com/SimplyAhmazing/noor
  42. @AnjanaVakil language to be acquired

  43. @AnjanaVakil we learn through context

  44. @AnjanaVakil we learn through context foo = bar('baz')

  45. @AnjanaVakil we learn through context result = analyze('data')

  46. @AnjanaVakil we learn out loud result = analyze('data')

  47. @AnjanaVakil result = analyze('data') “result equals analyze data” ? “set

    result to analyze of data” ? “analyze string data becomes result” ? … ? we learn out loud
  48. @AnjanaVakil “… can we really comprehend and communicate source code

    if we cannot vocalise it?” - Felienne Hermans, Computer Scientist we learn out loud
  49. @AnjanaVakil we can't learn alone

  50. @AnjanaVakil we can't learn alone The Recurse Center recurse.com

  51. @AnjanaVakil we can't learn alone The Recurse Center outreachy.org recurse.com

  52. @AnjanaVakil we can't learn alone The Recurse Center outreachy.org recurse.com

    mapbox.com/careers
  53. @AnjanaVakil code is language is collaboration is power

  54. @AnjanaVakil what will we do with it?

  55. @AnjanaVakil Thank you! GOTO Chicago team István "Flaki" Szmozsánszky, Perry

    Eising, Nicole Orchard, Max Rabkin, John Sylak-Glassman & everyone else who let me talk their ear off The Recurse Center Mapbox
  56. @AnjanaVakil - H. Abelson, G.J. Sussman, & J. Sussman, Structure

    and Interpretation of Computer Programs (1996), via mitpress.mit.edu/sicp - World Atlas of Language Structures, "Gender distinctions in Independent Personal Pronouns", via wals.info/feature/44A - M. Tomasello, "Language is Not an Instinct", in Cognitive Development 10 (1995) - P. van Roy, "Programming Paradigms for Dummies: What Every Programmer Should Know", in New Computational Paradigms for Computer Music (2009), via UCL - E. Dijkstra, "How do we tell truths that might hurt?" (1975), cited in V. Chandra, Geek Sublime (2014) - K.E. Iverson, "Notation as a tool of thought" (awarded 1979), in ACM Turing award lectures (2007), via ACM - Conway's Game of Life in Dyalog APL, from "APL (programming language)", Wikipedia - K. Thomas tweet (2015) via Twitter, via A. van Kesteren, "Avoid whitelist/blacklist" on Github - R. Nasser, "Arabic Programming Language at Eyebeam" (2013) via nas.sr/بﻠﻗ - A. Abdalla, "Creating an Arabic Programming Language!", !!Con 2018 - F. Hermans, "Code Phonology" (2018), via felienne.com/archives/5947 Image Credits - Icons by EmojiOne - "The Tower of Babel" painting by Pieter Bruegel the Elder (1563), via Wikimedia - "Syntax tree diagram of a sentence from Syntactic Structures (1957) by N. Chomsky" by Gringer, via Wikipedia/Wikimedia - Figure from Peter van Roy, "Programming Paradigms for Dummies: What Every Programmer Should Know" - Image from "Conway's Game of Life" via Cornell Math Explorers' Club - MATLAB logo image via MathWorks, R logo image via The R Foundation - Poster for Tron ©1982 Disney, image via IMDb References