🖥️
Intro to Computer Science (ICS3U/C)
  • An Introduction to Computer Science
  • Videos & Slides
  • Unit 1: In the Beginning
    • The History of Computers
    • Binary & Logic
      • Bits and Bytes (Binary)
      • Transistors (Changing Bits)
      • Logic Gates
        • Poster
        • Logic.ly
    • The Parts of a Computer
  • Unit 2: Intro to Code
    • How Do We Code?
      • Coding Conventions (Rules)
      • Commenting Code
    • What is HTML?
      • Hello World! (in HTML)
      • HTML Slideshow
    • Hello World!
    • Input / Output
      • The Console
      • Prompt, Alert, Confirm
    • Variables & Data
      • Strings (Text)
      • Numbers (Values)
        • Converting & Rounding
        • The Math Object
          • Random Numbers
      • Booleans
        • Truthiness
      • Arrays
  • Unit 3: Control Flow
    • Conditionals (if this, do that)
      • If...Else
        • Logical Operators
      • Switch / Case
      • Ternary Operators
    • Loops (Repeating Code)
      • For...Loop
      • While & Do/While Loops
    • Debugging
  • Unit 4: Functions
    • Functional Programming
    • User Defined Functions
      • Hoisting and Scope
    • Calling a JS Function
  • TL;DR
    • Programming Basics
    • Slideshows & Demos
    • Javascript Syntax Poster
  • Advanced Topics
    • Recursion
    • Structures & Algorithms
    • Mmm... Pi
  • External Links
    • Typing Club!
    • repl.it
    • Khan Academy
    • Geek Reading
    • ECOO CS Contest
Powered by GitBook
On this page
  • Dev Environment
  • Compiling vs Interpreting
  1. Unit 2: Intro to Code

How Do We Code?

PreviousThe Parts of a ComputerNextCoding Conventions (Rules)

Last updated 4 years ago

Coding (or programming, as I like to call it) is changing. What used to be done directly on a computer, with specific hardware, is becoming easier and more ubiquitous. These days you can develop your program completely and even deploy to a production server without having the files directly on your own computer. We've almost gone back to having .

I created on the topic, however it would be .

Dev Environment

Typically, you would set up a on your computer(s) to produce your code in the language(s) of your choosing. This might include an , or IDE. One of the most widely known IDE's is . Another is (one of my favourites). The IDE has a workspace for editing code files, highlighting syntax, compiling and debugging code, and even deployment or connecting to a version control system.

These days your dev environment, including very capable IDE's, are available online. Amazon is putting a lot of money into their , for example.

We will be using a teaching/learning IDE from . Below are some examples of other web-based development environments:

  • (formerly Cloud9 IDE)

The list could go on for quite some time. In fact, there is even .

The was designed to give developers full control of their environment. From colour and syntax-highlighting schemes to language to , autocomplete, and , Eclipse is a workhorse. For that reason, it is also extremely complicated and a bit bloated. It also has a steep learning curve.

Don't let that sound like a bunch of negatives towards Eclipse. It is extremely powerful and used across the globe for code development.

I am a tad biased, since I've been using various versions of MS Visual Studio since I was about 17 years old, but it is seriously worth a look - even (or especially) the express versions.

Visual Studio Code combines the simplicity of a source code editor with powerful developer tooling, like IntelliSense code completion and debugging.

First and foremost, it is an editor that gets out of your way. The delightfully frictionless edit-build-debug cycle means less time fiddling with your environment, and more time executing on your ideas.

Compiling vs Interpreting

Compiling

The procedure known as compiling is the act of running a program (the compiler) to read through your code and convert it to something a computer can understand. It might get compiled down to assembly or some other machine-level language that is meant for the processor to understand, not our human eyes - essentially to binary instructions.

Interpreting

Interpreted code, like JavaScript and Python, has a "middle-man" translating the code to machine language instruction-by-instruction. Instead of compiling all the code into machine language, it does this as necessary. This can be costly in terms of performance but also has many benefits like fixing code on-the-fly and using the same code for any kind of hardware.

There are many great videos on YouTube explaining the differences between compiled and interpreted code - I suggest you watch a couple and find the one which helps you the most.

Microsoft gets a bad wrap for no good reason. People who dislike Microsoft products do not know what they're missing when it comes to development environments and . Even back in 1999-2000 with version 5, the environment was solid, mature, and full of incredible features designed to make programming faster and more professional.

By far, one of the best code editors out there is Visual Studio Code. It is not a complete dev environment, but plug-ins can get it pretty close. From their :

MS Visual Studio
own site
in the cloud
dumb terminals
Here is a slideshow
better with an explanation
development environment
Integrated Development Environment
Eclipse
MS Visual Studio
AWS system
Repl.it
Codenvy
Codeanywhere
Koding
ShiftEdit
Amazon C9
Paiza Cloud
Eclipse Che
Eclipse IDE
plugins
linting
debugging
The Eclipse IDE allows you to program in several languages using plug-ins
Visual Studio has been around since the 90's and is a very mature product