โ† All B.S.W.E. Bachelor of Software Engineering Flashcard Decks

Programming Languages & Paradigms Flashcards

7 cards from real B.S.W.E. Bachelor of Software Engineering practice questions. Tap to flip, then mark Knew It or Still Learning โ€” missed cards come back until you master them.

Read the first 7 Programming Languages & Paradigms flashcards as text
  1. Which of the following best describes a strongly typed programming language?

    Answer: A language that enforces type constraints and restricts implicit type conversions

    A strongly typed language enforces type constraints at compile or runtime and does not allow implicit coercions between incompatible types.

  2. Which programming paradigm treats computation as the evaluation of mathematical functions and emphasizes immutability?

    Answer: Functional programming

    Functional programming models computation as the evaluation of pure mathematical functions, emphasizing immutability and the avoidance of side effects.

  3. What is the primary role of a compiler in the software development process?

    Answer: To translate source code into machine code before execution

    A compiler translates the entire source program into machine code (or intermediate code) before execution, unlike an interpreter which processes code at runtime.

  4. Which of the following is the best example of a declarative programming language?

    Answer: SQL

    SQL is declarative because the programmer specifies what data to retrieve without defining the step-by-step procedure for how to retrieve it.

  5. What does dynamic typing mean in the context of programming languages?

    Answer: Types are checked at runtime rather than at compile time

    In dynamically typed languages, type checking is performed at runtime, allowing variables to hold values of any type without explicit prior declarations.

  6. What does 'garbage collection' refer to in programming language runtimes?

    Answer: Automatic reclamation of heap memory no longer referenced by the program

    Garbage collection is an automatic memory management technique that identifies and frees heap memory that is no longer reachable by any live references in the program.

  7. Which of the following best describes the concept of a 'closure' in programming?

    Answer: A function that captures and retains variables from its enclosing lexical scope

    A closure is a function bundled together with references to its surrounding lexical environment, retaining access to those variables even after the enclosing scope has returned.