OLD | NEW |
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 import 'dart:convert'; | 5 import 'dart:convert'; |
6 import 'dart:io'; | 6 import 'dart:io'; |
7 | 7 |
8 main() { | 8 main() { |
9 String canary = "Canary"; | |
10 String spades = "These are three black spades: ♠♠♠"; | 9 String spades = "These are three black spades: ♠♠♠"; |
11 String german = "German characters: aäbcdefghijklmnoöpqrsßtuüvwxyz"; | 10 String german = "German characters: aäbcdefghijklmnoöpqrsßtuüvwxyz"; |
12 | 11 |
13 stdout.writeln(canary); | |
14 stdout.writeln(spades); | 12 stdout.writeln(spades); |
15 stdout.writeln(german); | 13 stdout.writeln(german); |
16 print(spades); | 14 print(spades); |
17 print(german); | 15 print(german); |
18 | 16 |
19 stdout.add(canary.runes.toList()); | 17 stdout.add(spades.runes.toList()); |
| 18 stdout.writeln(); |
| 19 stdout.add(german.runes.toList()); |
20 stdout.writeln(); | 20 stdout.writeln(); |
21 | 21 |
22 stdout.writeln(canary); | 22 stdout.add(spades.codeUnits); |
| 23 stdout.writeln(); |
| 24 stdout.add(german.codeUnits); |
| 25 stdout.writeln(); |
| 26 |
23 stdout.writeln(spades); | 27 stdout.writeln(spades); |
24 stdout.writeln(german); | 28 stdout.writeln(german); |
25 print(spades); | 29 print(spades); |
26 print(german); | 30 print(german); |
27 | 31 } |
28 stdout.add(canary.codeUnits); | |
29 stdout.writeln(); | |
30 } | |
OLD | NEW |