Troubles the Emperors of Blefuscu did frequently expostulate by their

Troubles the emperors of blefuscu did frequently

This preview shows page 26 - 35 out of 50 pages.

Troubles, the Emperors of Blefuscu did frequently expostulate by their Ambassadors, accusing us of making a Schism in Religion, by offending against a fundamental Doctrine of our great Prophet Lustrog, in the fifty-fourth Chapter of the Brundrecal (which is their Alcoran.) This, however, is thought to be a meer Strain upon the Text: For the Words are these: That all true Believers shall break their Eggs at the convenient End: and which is the convenient End, seems, in my humble Opinion, to be left to every Man's Conscience, or at least in the power of the Chief Magistrate to determine. Now the Big-Endian Exiles have found so much Credit in the Emperor of Blefuscu's Court, and so much private Assistance and Encouragement from their Party here at home, that a bloody War has been carried on between the two Empires for six and thirty Moons with various Success; during which time we have lost forty Capital Ships, and a much greater number of smaller Vessels, together with thirty thousand of our best Seamen and Soldiers; and the Damage received by the Enemy is reckon'd to be somewhat greater than Ours. However, they have now equipped a numerous Fleet, and are just preparing to make a Descent upon us; and his Imperial Majesty, placing great Confidence in your Valour and Strength, has commanded me to lay this Account of his affairs before you. 26
Image of page 26
"Example" in different encodings ASCII: 45 78 61 6d 70 6c 65 UTF-16BE: FE FF 00 45 00 78 00 61 00 6d 00 70 00 6c 00 65 UTF-16LE: FF FE 45 00 78 00 61 00 6d 00 70 00 6c 00 65 00 27
Image of page 27
What about new line (end of line)? LF (Line feed, '\n', 0x0A, 10 decimal) CR (Carriage return, '\r', 0x0D, 13 in decimal) Different systems represent newline differently Window: \r\n Unix based: \n Old Mac: \r 28
Image of page 28
29 Carriage return lever Carriage Lever Type hammer A type writer ribbon Paper
Image of page 29
Unicode Unicode standard defines a number of characters that conforming applications should recognize as line terminators: LF: Line Feed, U+000A VT: Vertical Tab, U+000B FF: Form Feed, U+000C CR: Carriage Return, U+000D CR+LF: CR (U+000D) followed by LF (U+000A) NEL: Next Line, U+0085 LS: Line Separator, U+2028 PS: Paragraph Separator, U+2029 30
Image of page 30
Roadmap Character encoding ASCII Unicode JSON XML 31
Image of page 31
JSON (Javascript Object Notation) Light-weight data exchange format Much simpler than XML Language-independent Inspired by syntax of JavaScript object literals Some differences from JavaScript objects, e.g., String in JSON must be double-quoted Ok to single-quote in JavaScript (& Python) 32
Image of page 32
Syntax of JSON value = string|number|object|array|true|false|null object = {} | { members } members = pair | pair, members pair = string : value array = [] | [ elements ] elements = value | value elements 33
Image of page 33
Valid JSON or not?
Image of page 34
Image of page 35

You've reached the end of your free preview.

Want to read all 50 pages?

  • Fall '14
  • Character encoding, ASCII, Carriage return, Unicode, Blefuscu

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture