---
title: Eboard 18  Transforming XML
number: 18
section: eboards
held: 2019-03-06
link: true
---
CSC 151 2019S, Class 18:  Transforming XML
==========================================

_Overview_

* Preliminaries
    * Notes and news
    * Upcoming work
    * Extra credit
    * Questions
* About exam 2
* Labs

Preliminaries
-------------

### News / Etc.

* Mentor sessions Wednesday 8-9 p.m., Thursday 8-9 p.m., Sunday 5-6 p.m.
* Apologies for getting readings out later than I would like.  The past
  few weeks have been just a bit too busy.  The conference did not help,
  nor did two unexpected, time-consuming administrative tasks.  I expect
  to be a bit more caught up after break.
* There are two labs for today, one on processing XML and one on
  transforming XML.  We'll see how far we get on the first before
  moving on to the second.
* Apologies for my behavior toward one of you in class on Monday (who isn't
  here today).
    * I was not intending to be challenging, but it appears I was.
    * I know that it is hard to feel like your teacher is challenging
      you.
    * I will do my best to do better in the future.
* Believe or not, but Monday's "snarky sam" is my more traditional mode
  of behavior.  I've been trying to tone it done this year (and, it appears,
  I've succeeded).  Given that you've seen this alternative mode of teaching,
  we should probably discuss it.
* We also need to chat a bit about our Code of Conduct, or at least how people
  are and are not upholding our Code of Conduct.  
    * Issues I've heard about include
        * People "splitting up" the work on a homework assignment.
        * People meeting their partner having completed one or more problems
          in advance.
        * People doing the lab before class.
        * People impatient with their partner for being "too slow".
        * People feeling "too slow" and tuning out.
    * Resolutions?
        * Reminder of the importance of the CoC
        * Potential partnering processes for homework
            * I like to zoom because I'm so awesome
            * I like to reflect because I'm even more awesome
            * I'm awesome, but somewhere in the middle
            * You can change your decision after trying it out

### Upcoming work

* Reading for Friday
    * [Debugging](../readings/debugging) (to be posted tonight)
* [Exam 2](../exams/exam02) due Tuesday.
    * Prologue due Friday night
* [Flash cards](../flashcards/flashcards07) due Tonight at 8:00 p.m.
    * Covers Wednesday/Friday/Monday classes
* Quiz Friday: Hash tables and structs

### Extra Credit

_I would certainly appreciate suggestions of other extra credit activities
(preferably via email)._

#### Extra credit (Academic/Artistic)

#### Extra credit (Peer)

* Grinnell Singers, Sunday at 2pm. with Lyra Baroque Orchestra (professional
  musicians, period instruments), really difficult pieces by Handel and
  others.
* Twelfth Night this weekend

#### Extra credit (Wellness)

#### Extra credit (Wellness, Regular)

* 30 Minutes of Mindfulness at SHACS every Monday 4:15-4:45
* Any organized exercise.  (See previous eboards for a list.)
* 60 minutes of some solitary self-care activities that are unrelated to
  academics or work.  Your email reflection must explain how the activity
  contributed to your wellness.
* 60 minutes of some shared self-care activity with friends. Your email
  reflection must explain how the activity contributed to your wellness.

#### Extra credit (Misc)

### Other good things 

### Questions

_Why can't I update `loudhum` on my computer?_

> We are now relying on a bunch of other libraries.  See the labs and
  the readings for the full list.

_How do I access MathLAN remotely?_

> <https://karp.cs.grinnell.edu>

_Will you release more office hours?_

> Yes, as soon as we start lab.

> I have now released some on Thursday afternoon.  You can also email me
  for 10:00, 10:15, 3:30, and 3:45.  (Sorry, I can't figure out how to
  make those appear on the scheduling program.)

_Will you publish flash cards?_

> Yes.  The template is now in place.  I'll add questions this afternoon
  or evening.

_Will you tell us how long you expect each problem to take?_

> Sure.

About exam 2
------------

Fun!

Lab
---

Start with Monday's lab.  Then do Wednesday's.

What are the goals for 1?  

> To get you used to switching between the string representation with
  lots and lots of tags, and the list representation.

What do you want for 1c?

```drracket
(define aphorisms
  '(ul (li "A penny saved is a penny earned.")
       (li "Time flies like an arrow.")
       (li "Fruit flies like an apple.")))
```

What do you want for 1d?

```drracket
> (xml->string aphorisms)
```

What pattern would you use for the "`em` tag"?

> `#px<em[^>]*>"` 

> More generally, `#px"<[Ee][Mm][^>]*>"`

What if I want to preserve the attributes?

> I'd use `#px"<[Ee][Mm]([^>]*)>"` as the pattern and `"<strong\\1>"`
  as the replacement.

What's the lab writeup?

> There is no lab writeup.  Spend time thinking about the exam.

