Skip to content

Latest commit

 

History

History
30 lines (23 loc) · 1.59 KB

README.md

File metadata and controls

30 lines (23 loc) · 1.59 KB

PureFunctions

Skillbox homework 15.5 on the topic "Pure Functions"

Goals

  1. Read the article about functional programming Функциональный Swift.
  2. Write in your own words what Pure Function is.
  3. Sort the array of numbers in ascending order using the Sorted function.
  4. Convert an array of numbers to an array of strings using the Map function.
  5. Use the Reduce function to convert an array of strings with people's names into a single string containing all of these names.
  6. Write a function that accepts a function with the type (Void) - > Void, which will be called with a delay of two seconds.
  7. Write a function that accepts two functions and returns a function that, when called, executes the first two functions.
  8. Write a function that sorts the array according to the passed algorithm: it takes an array of numbers and a function that takes two numbers as input, returns
  9. Bool (whether the first number should go after the second), and returns an array sorted according to this algorithm.
  10. Write in your own words what infix -, suffix -, prefix-operators are.

🔗 Main point

Implemented a collection with pure functions. When you click on a collection cell, the corresponding clean function is called



Image alt Image alt

What is involved

  1. Implementing pure functions
  2. Table view collections and custom xib cell
  3. Navigation stack transitions
  4. Pure functions autotests