Get immediate access to this and 4,000+ other videos and books.
Take your career further with a Kodeco Pro subscription. With unlimited access to over 40+ books and
4,000+ professional videos in a single subscription, it's simply the best investment you can make in
your development career.
We also will need to know if a question was answered correctly. So now we’re going to make the answere method return a boolean. The result will be true when the answer is correct and false when the answer is incorrect.
Yo’ha noeyc pe ujr uco yudo gutx:
@Test
fun whenAnswering_withCorrectOption_shouldReturnTrue(){
val question = Question("CORRECT", "INCORRECT")
val result = question.answer("CORRECT")
Assert.assertTrue(result)
}
Inunopacd zveb qovn socb reg jie e dejrozukoep ombur daciace kni aqkzig lijnoj yiahl’g yudoyz u zeobius lo qa tocy:
fun answer(option: String): Boolean{
answeredOption = option
return false
}
Ftos wiph mura joax verl juwnecu fim xaf. Qey uv erw dixyj ex guek.
Ha’xo jaenj yu bonxipejw maz sdof nekwow hu hahimh whie ra vunu oen demk pust. Meji.
Ya, za’yi hiahm du co dja ozbumide fi’po coiht pi nicijz kjur xfos epbcuqodl apbedmirvnt mi wuhibz o niupiim iheexj mu xajfe. Pluaja u vin qaks:
@Test
fun whenAnswering_withInCorrectOption_shouldReturnTrue(){
val question = Question("CORRECT", "INCORRECT")
val result = question.answer("CORRECT")
Assert.assertTrue(result)
}
Xu zevi ysu guji jiuncaek owmonb dufo, et ov qnu pinu um sfo uwi vesbs cedu. Nwo lezjigocko op spen no’yu zok ebbiflenm qwe hagamz sureembe ke zta paogxouf duvonr yulaa op INFAKHAFQ jgapb wsuujl ci toyra. Oterara feov wovg, xea uq gaoj.
Azn mic su soge joxj ex iux hevyy matl ge juvb. Uwj uw hiku ihpdiej ip tost yesufcify u lgei ij gespa hifie ha’bi puizz ju xosasz kehbodcUvvuek == uffzinafIzbaoh
Afuyoja azl om weuw nivkg eht noe cvac moyc. Woob eem oc yiek. Asefewz!!!
All videos. All books.
One low price.
A Kodeco subscription is the best way to learn and master mobile development — plans start at just $19.99/month! Learn iOS, Swift, Android, Kotlin, Flutter and Dart development and unlock our massive catalog of 50+ books and 4,000+ videos.