English subtitles

← 03-09 An Arithmetic Grammar

dummy description

Get Embed Code
3 Languages

Showing Revision 1 created 05/04/2012 by Amara Bot.

  1. And in fact, this general notion is one of the greater glories
  2. of context-free grammars.
  3. The grammar is finite.
  4. We can write it down.
  5. But for a non-trivial grammar, the number of possible utterances is infinite.
  6. Just by following simple replacement rules,
  7. I can make bigger and bigger utterances until I get tired and eventually pick terminals.
  8. And in fact, a number of academics, including Chomsky,
  9. argued that this is one of the ways or one of the reasons
  10. that our finite human brains--I myself am a bear of very little brain--
  11. can produce an infinite number of potential creative ideas.
  12. A finite amount of matter can produce an infinite number of utterances.
  13. That's a relatively heady notion, so I'm going to skip past it for now.
  14. And it turns out that we're going to be able to see this same sort of infinity
  15. of possible utterances in computer languages like Python or JavaScript.
  16. Wow, my infinity symbol needs work.
  17. This gets a label because otherwise you might not be able to tell.
  18. In both of these languages, you can write down arithmetic expressions.
  19. You can imagine them being generated from an arithmetic expression grammar like this.
  20. Exp is just an abbreviation for expression.
  21. And in fact, were your student senses tingling?
  22. It's time for a quiz on this.
  23. Given this arithmetic grammar,
  24. check all of these utterances that are valid exp's, that are valid expressions.
  25. Starting from expression, which of these 5 options can I generate?
  26. Check all that apply.