Skip to content

Latest commit

 

History

History
 
 

00268-easy-if

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 

If easy #utils

by Pavel Glushkov @pashutk

Take the Challenge    简体中文 日本語 한국어

Implement a utils If which accepts condition C, a truthy return type T, and a falsy return type F. C is expected to be either true or false while T and F can be any type.

For example:

type A = If<true, 'a', 'b'>  // expected to be 'a'
type B = If<false, 'a', 'b'> // expected to be 'b'

Back Share your Solutions Check out Solutions