From d529f12cabc01ed907cc52cc5c46cf5c9af0c855 Mon Sep 17 00:00:00 2001 From: Zhao Gang Date: Sun, 6 May 2018 21:33:44 +0800 Subject: [PATCH 1/2] Fix a typo Actually the filter filters out odd ones, leaving the even ones. --- Part 2 - Sequence Basics/2. Reducing a sequence.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Part 2 - Sequence Basics/2. Reducing a sequence.md b/Part 2 - Sequence Basics/2. Reducing a sequence.md index e22c0b0..4febf8a 100644 --- a/Part 2 - Sequence Basics/2. Reducing a sequence.md +++ b/Part 2 - Sequence Basics/2. Reducing a sequence.md @@ -20,7 +20,7 @@ public final Observable filter(Func1 predicate) ![](https://raw.github.com/wiki/ReactiveX/RxJava/images/rx-operators/filter.png) -We will use `filter` to create a sequence of numbers and filter out all the even ones, keeping only odd values. +We will use `filter` to create a sequence of numbers and filter out all the odd ones, keeping only even values. ```java Observable values = Observable.range(0,10); From 5982ab960b2f6fd96cf7c4cd02650eafc2023c4e Mon Sep 17 00:00:00 2001 From: Zhao Gang Date: Thu, 10 May 2018 21:15:41 +0800 Subject: [PATCH 2/2] Fix another typo The range function should be Observable.range(3,7) instead of Observable.range(3,4) --- Part 2 - Sequence Basics/5. Transformation of sequences.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Part 2 - Sequence Basics/5. Transformation of sequences.md b/Part 2 - Sequence Basics/5. Transformation of sequences.md index 95bccd8..335074c 100644 --- a/Part 2 - Sequence Basics/5. Transformation of sequences.md +++ b/Part 2 - Sequence Basics/5. Transformation of sequences.md @@ -57,7 +57,7 @@ Map: 6 Map: Completed ``` -This was something we could do without `map`, for example by using `Observable.range(3,4)`. In the following, we will do something more practical. The producer will emit numeric values as a string, like many UIs often do, and then use `map` to convert them to a more processable integer format. +This was something we could do without `map`, for example by using `Observable.range(3,7)`. In the following, we will do something more practical. The producer will emit numeric values as a string, like many UIs often do, and then use `map` to convert them to a more processable integer format. ```java Observable values =