Published Dec 22, 2018

94. Data Structures - Primitives

    Delve into the essential world of data structures and primitives as the hosts decode the intricacies of JavaScript and C#, unravel the mysteries of floating point numbers, and underscore the crucial role these elements play in organizing and processing data efficiently.
    Episode Highlights
    Coding Blocks logo

    Popular Clips

    Episode Highlights

    • Primitive Types

      Primitive types are the foundational building blocks in programming languages, akin to atoms in the universe. Joe Zack explains that these types, such as booleans and integers, are the simplest forms that cannot be broken down further 1. While languages like C# have built-in types like strings, these are not considered primitives because they are composed of other elements. He notes, "There's primitive type and I couldn't really find a definitive answer on like what kind of they used to, to make that distinction" 2. Understanding these distinctions helps programmers grasp the quirks of different languages.

         

      Language Quirks

      JavaScript and C# handle primitive types differently, with each language having unique quirks. In JavaScript, all numbers are of the type 'number', including special cases like NaN (Not a Number), which paradoxically is considered a number 3. Joe Zack humorously points out, "Not a number is a number," highlighting JavaScript's peculiarities. C#, on the other hand, distinguishes between floating and fixed points, with floating points offering efficiency for certain calculations 4. These differences illustrate the diverse approaches languages take in handling basic data types.

    Related Episodes