Question · JavaScript and TypeScript course · Module 9: Design Patterns and Architecture

Pure Functions

What characterizes a pure function?

Answer options

  • A function written without using variables
  • For the same arguments it always returns the same result and has no side effects
  • A function that works only with primitive types
  • A function that takes no arguments

You can check the correct answer by solving this task in the CodeWorlds game.