301 Quotes About Programming



  • Author Brian Goetz
  • Quote

    Sometimes abstraction and encapsulation are at odds with performance — although not nearly as often as many developers believe — but it is always a good practice first to make your code right, and then make it fast.

  • Tags
  • Share


  • Author Michael Feathers
  • Quote

    Legacy code. The phrase strikes disgust in the hearts of programmers. It conjures images of slogging through a murky swamp of tangled undergrowth with leaches beneath and stinging flies above. It conjures odors of murk, slime, stagnancy, and offal. Although our first joy of programming may have been intense, the misery of dealing with legacy code is often sufficient to extinguish that flame.

  • Tags
  • Share

  • Author Dan Salomon
  • Quote

    Sometimes it pays to stay in bed on Monday, rather than spending the rest of the week debugging Monday's code.

  • Tags
  • Share

  • Author Brian Goetz
  • Quote

    Whenever more than one thread accesses a given state variable, and one of them might write to it, they all must coordinate their access to it using synchronization.

  • Tags
  • Share

  • Author Brian Goetz
  • Quote

    The possibility of incorrect results in the presence of unlucky timing is so important in concurrent programming that it has a name: a race condition. A race condition occurs when the correctness of a computation depends on the relative timing or interleaving of multiple threads by the runtime; in other words, when getting the right answer relies on lucky timing.

  • Tags
  • Share

  • Author Brian Goetz
  • Quote

    When a field is declared volatile, the compiler and runtime are put on notice that this variable is shared and that operations on it should not be reordered with other memory operations. Volatile variables are not cached in registers or in caches where they are hidden from other processors, so a read of a volatile variable always returns the most recent write by any thread.

  • Tags
  • Share