M&IB Devx - Code Quality

20 Questions | Total Attempts: 99

SettingsSettingsSettings
Please wait...
M&IB Devx - Code Quality

This is part of the DevX course assessment that will be taken by delegates before and after the programme.


Questions and Answers
  • 1. 
    Whose responsibility is it to ensure unexpected answers are handled?
    • A. 

      Business Analyst

    • B. 

      Lead programmer

    • C. 

      End user

    • D. 

      Programmer

  • 2. 
    If an action is expected and unwanted , what should the programmer do?
    • A. 

      Use unexpected techniques to handle the problem

    • B. 

      Not worry about it - the business analyst deals with this

    • C. 

      Plan for and implement the best method of removing the unwanted action

    • D. 

      None of the above

  • 3. 
    Why are silent discards bad?
    • A. 

      Assumes an unknown scenario is ok

    • B. 

      Regulatory agencies want everything recorded

    • C. 

      Difficult to explain to end users

    • D. 

      Can lead to unhandled errors

  • 4. 
    What are the first steps in defensive programming?
    • A. 

      Challenge, understand, eliminate, document all assumptions

    • B. 

      Create data validation module for incoming data

    • C. 

      Know the domain you are working in

    • D. 

      Write use case for unexpected actions

  • 5. 
    Which of the following statements is true about mutable data in a multi-threaded environment?
    • A. 

      Prevent the use of locks

    • B. 

      Must be locked and unlocked

    • C. 

      Used only by thread safe processes

    • D. 

      All of the above

  • 6. 
    Select TWO of the following things that software quality tools detect
    • A. 

      Duplicate code

    • B. 

      Non-conformance with coding standards

    • C. 

      Test coverage

    • D. 

      Uncommon bugs

  • 7. 
    Which of these is a benefit of generational garbage collection?
    • A. 

      The ability to have concurent deallocation of objects at once

    • B. 

      The ability to optimize garbage collection performance

    • C. 

      The abiltiy to manually deallocate objects

    • D. 

      The ability to have pluggable garbage collection algorithms

  • 8. 
    Objects with finalizers require two garbage collection cycles to get deallocated
    • A. 

      True

    • B. 

      False

  • 9. 
    Adding more resources to a single node in the system is called…
    • A. 

      Vertical scaling

    • B. 

      Horizontal scaling

    • C. 

      Continuous deployment

    • D. 

      Pluggalble architeture

  • 10. 
    Mutable objects may be bad for performance in what way?
    • A. 

      They are more difficult to garbage collect

    • B. 

      They require more memory than immutable objects

    • C. 

      They require making more frequent defensive copies

    • D. 

      They generate more network traffic

  • 11. 
    Benchmarking is a critical component of performance tuning
    • A. 

      True

    • B. 

      False

  • 12. 
     In general, code performance is more important than good design
    • A. 

      True

    • B. 

      False

  • 13. 
    Code quality tools remove the need for programmers is visually inspect code.
    • A. 

      True

    • B. 

      False

  • 14. 
    Which term best describes the future cost of design tradeoffs to meet short-term goals
    • A. 

      Code smell

    • B. 

      Optimization

    • C. 

      Design pattern

    • D. 

      Technical debt

  • 15. 
     If an exception is caught and rethrown logging is not necessary
    • A. 

      True

    • B. 

      False

  • 16. 
    Maps or Dictionaries are best under which circumstance?
    • A. 

      Fast iteration is needed

    • B. 

      Order of data is important

    • C. 

      Random access is needed

    • D. 

      Small datasets are in use

  • 17. 
    Select TWO of the following which are disadvantages of inserting timing calling into code
    • A. 

      They are inconvenient for developers to use

    • B. 

      They do not measure actual CPU time

    • C. 

      They require an application to be rebuilt

    • D. 

      They only work well in production

  • 18. 
    A 2x speedup of a method invocation should always be considered valuable
    • A. 

      True

    • B. 

      False

  • 19. 
    A disadvantage of Sonar is its lack of configurability
    • A. 

      True

    • B. 

      False

  • 20. 
    Select three of the following that are true when developing software logging:
    • A. 

      An overhead

    • B. 

      Required

    • C. 

      Expensive

    • D. 

      All log messages are displayed

Related Topics
Back to Top Back to top