Skip to content

Watched an MIT lecture

April 13, 2011

I watched This lecture and it has been very informative.

I learned the difference between Static and Dynamic typing, as well as the difference between strong and weak type checking.

Static typing states that once a variable has been given a type, it cannot be changed until it goes out of scope.

Dynamic typing is the exact opposite of that, you can change types as you want anytime you want.

Wikipedia defines strong typing as “the prevention of a successful execution of an operation on arguments which have the wrong type.”

For example, if you’re mixing integers with strings in a strongly typed language, this will result in a compile-time error.

While weakly typed languages try to cast one of the operands to perform the requested operation.

I also learned that when writing a test case, like an if statement, one should consider all possible cases that might occur.

As failing to do so usually results in bugs.

Since the course is being taught in python, and I’m a Java programmer, I understood why python uses indentation, it’s simply python’s way of grouping statements together, much like curled brackets “{}” in C-Like languages, like Java.

Advertisements

From → General

Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: