@@ -49,7 +49,7 @@ object NamedandDefaultArguments
49
49
* printName(last = "Jones") // Prints "John Jones"
50
50
* }}}
51
51
*
52
- * Given classes below:
52
+ * Given the classes below:
53
53
*
54
54
* {{{
55
55
* class WithoutClassParameters() = {
@@ -84,19 +84,18 @@ object NamedandDefaultArguments
84
84
*
85
85
* }}}
86
86
*
87
- * Can specify arguments in any order if you use their names:
87
+ * You can specify arguments in any order if you use their names:
88
88
*/
89
89
def classWithoutParametersNamedandDefaultArguments (res0 : Int , res1 : Int , res2 : Int ) = {
90
90
val me = new WithoutClassParameters ()
91
91
92
- // what happens if you change the order of these parameters (nothing)
92
+ // What happens if you change the order of these parameters? Nothing.
93
93
val myColor = me.addColors(green = 0 , red = 255 , blue = 0 )
94
94
95
- // for koan, remove the values in the should equal
96
95
myColor should equal((res0, res1, res2))
97
96
}
98
97
99
- /** Can default arguments if you leave them off:
98
+ /** You can default arguments if you leave them off:
100
99
*/
101
100
def defaultArgumentsNamedandDefaultArguments (res0 : Int , res1 : Int , res2 : Int ) = {
102
101
val me = new WithoutClassParameters ()
@@ -105,7 +104,7 @@ object NamedandDefaultArguments
105
104
myColor should equal((res0, res1, res2))
106
105
}
107
106
108
- /** Can access class parameters and specify arguments in any order if you use their names:
107
+ /** You can access class parameters and specify arguments in any order if you use their names:
109
108
*/
110
109
def anyOrderNamedandDefaultArguments (res0 : Int , res1 : Int , res2 : Int ) = {
111
110
val me = new WithClassParameters (40 , 50 , 60 )
@@ -114,7 +113,7 @@ object NamedandDefaultArguments
114
113
myColor should equal((res0, res1, res2))
115
114
}
116
115
117
- /** Can access class parameters and default arguments if you leave them off:
116
+ /** You can access class parameters and default arguments if you leave them off:
118
117
*/
119
118
def accessClassParametersNamedandDefaultArguments (res0 : Int , res1 : Int , res2 : Int ) = {
120
119
val me = new WithClassParameters (10 , 20 , 30 )
@@ -123,7 +122,7 @@ object NamedandDefaultArguments
123
122
myColor should equal((res0, res1, res2))
124
123
}
125
124
126
- /** Can default class parameters and have default arguments too:
125
+ /** You can default class parameters and have default arguments too:
127
126
*/
128
127
def defaultClassArgumentsNamedandDefaultArguments (res0 : Int , res1 : Int , res2 : Int ) = {
129
128
val me = new WithClassParametersInClassDefinition ()
0 commit comments