English subtitles

← 05-07 Syllepsis

dummy description

Get Embed Code
3 Languages

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

  1. In fact, in English--and in fact, in Greek--there is a particular form of word play
  2. called syllepsis, based on exploiting this semantic incongruity.
  3. Let me give you an example of what it looks like in natural language,
  4. and then we'll bring it back to HTML.
  5. In this fragment: "she made no reply, up her mind, and a dash for the door"
  6. "made" is being applied to three different things--replies,
  7. make up a mind, and make a dash for some location.
  8. And it means something slightly different in each of these.
  9. Making a reply means to speak.
  10. Making up your mind means to decide something.
  11. And making a dash for the door means to run for the exit.
  12. But because we have this one function, if you'll permit me,
  13. being applied to these three different types of arguments,
  14. there's an incongruity which some may find humorous.
  15. Here's perhaps my favorite example from the same source.
  16. "She lowered her standards by raising her glass, her courage,
  17. her eyes, and his hopes."
  18. This is a very good but very disconcerting poem
  19. and a lovely example of syllepsis.
  20. Lowered is being applied to standards;
  21. that means to give up your ideals or try something worse.
  22. Raising her glass, as if in a toast.
  23. Raising her courage--to muster up her willpower.
  24. Raising her eyes to look up at someone.
  25. And raising his hopes because, well, nothing good happens in this poem.
  26. Similarly, there's an error in HTML known as mismatched tags.
  27. We talked about balanced parentheses in parsing--
  28. the same number of As followed by the same number of Bs,
  29. or the same number of open parentheses followed by
  30. the same number of closed parentheses.
  31. Recall that that's not something we can do with regular languages
  32. or regular expressions, but we can capture it with a context-free grammar.
  33. However, we didn't handle it in our parser,
  34. so we must handle it now.
  35. This concept is not particularly tricky,
  36. but it does require a context-free grammar.
  37. So just to make sure that we're all on the same page,
  38. there's a bit of a quiz.
  39. I have written three HTML fragments,
  40. but I've left some things blank.
  41. What I would like you to do is fill in each blank with the word
  42. necessary for each fragment alone to be well-balanced HTML,
  43. to have its tags match up perfectly.