Challenge: Create an Anonymous Function
Taak
Swipe to start coding
Write three anonymous functions in R and assign them to variables as described below:
- Create an anonymous function that adds 3 to its input and assign it to the variable
add_three. - Create an anonymous function that returns
TRUEif a number is even, and assign it to the variableis_even. - Create an anonymous function that concatenates two strings (with no separator), and assign it to the variable
concat_strings.
Each function should be assigned to the specified variable name. Do not use named function definitions for this task.
Oplossing
Was alles duidelijk?
Bedankt voor je feedback!
Sectie 2. Hoofdstuk 2
single
Vraag AI
Vraag AI
Vraag wat u wilt of probeer een van de voorgestelde vragen om onze chat te starten.
Geweldig!
Completion tarief verbeterd naar 5.56
Challenge: Create an Anonymous Function
Veeg om het menu te tonen
Taak
Swipe to start coding
Write three anonymous functions in R and assign them to variables as described below:
- Create an anonymous function that adds 3 to its input and assign it to the variable
add_three. - Create an anonymous function that returns
TRUEif a number is even, and assign it to the variableis_even. - Create an anonymous function that concatenates two strings (with no separator), and assign it to the variable
concat_strings.
Each function should be assigned to the specified variable name. Do not use named function definitions for this task.
Oplossing
Was alles duidelijk?
Bedankt voor je feedback!
Sectie 2. Hoofdstuk 2
single