Why TRUE + TRUE = 2: Data Types

preview_player
Показать описание


Directed by Tomek

and on Instagram as tomscott
Рекомендации по теме
Комментарии
Автор

0:19 the way the text on the screen and Tom's hand raise at the same time is unsettling

lucabaldassi
Автор

PHP: "A language notable for MANY questionable design decisions"

I laughed, cried and grimaced so hard at the mention of that absolutely true fact.

MrMysticphantom
Автор

"I have been coding for about 30 years"
Jesus, in my mind you've been permanently ~25 since 2015. I have to readjust to what Wikipedia claims is your age, but even then, you started super young if that's true...

rekagaal
Автор

I was taught Fortran at University. They told us to start with "implicit none" and then declare all our variable explicitly

Kind of a pain, but it did mean if you accidentally typo'd a variable name it would flag it for you immediately

HorzaPanda
Автор

When “true + true” fades away it doesn’t fully disappear 4:35

Sorry Tom, I’m a big fan of your work

kdlk
Автор

"Implicit conversions are great" - Famous last words

Tyranisaur
Автор

Thanks for undermining my trust in high-level programming languages. I'm switching to Assembly.

vaclavtrpisovsky
Автор

I really like strongly typed languages. If I want to cast it I can do it myself. Otherwise I want to see an error.

FinBoyXD
Автор

Tom is the kind of guy you listen to, even if you worked yourself through that topic countless times before

Concerning the topic itself, I prefer explicit declarations, as it makes finding bugs in the program simpler as it forces you to consciously account for these kind of conflicts. I can see why people like to use weak typing, but personally, I rather do not

tyberfen
Автор

I change the hdmi 1 to hdmi 2 and thats already enough coding for my grandparents

dontaskmewhy
Автор

Personally, I get really frustrated working with weakly typed languages. Debugging can be hard, but even just understanding what the code is doing can be harder.

BenjaminLovelady
Автор

I'll add that you can have implicit declarations within a strongly typed language. Swift does this as an example. So you can make a declaration like
var x = "50"
You don't need to declare that x is a string, the declaration is implicit. But in usage it'll be strongly typed, so
var y = 50
x+y
only works if you explicitly cast either of them, like
Int(x)+y

Recent Java also has implicit local declaration, though not for global variables.

casperes
Автор

In python, however, "1.5"*2 is "1.51.5"...

anselmschueler
Автор

4:57 That's why I used the mnemonic "explicitly equals" when writing booleans to remind me to use the second equal. The alliteration and second word reminded me that it was two symbols and not just the one.

RussanoGreenstripe
Автор

As someone who learned to program in C with a professor that kinda hated weak typing I'm screaming internally at the notion of asking if a string is true, it feels like asking if an apple is a number.

axelprino
Автор

2:46 the type of a variable doesn't get figured out ("inferred") from the code in JS / Python / PHP. Some languages do work like that, but JS just makes a bucket that can fit everything (with quite some overhead) and then just lets you do whatever you want with it.
Haskell is a language where it does get inferred from the code using constraint resolution, giving you the (apparent) benefits of not specifying it without that overhead. C#/Java have var, Kotlin has var/val, Scala/Rust have let, C++ has auto, all like Haskell (to various degrees).

FlashMustache
Автор

"Weak typing can reduce frustration and just make programmers' lives easier."

Weak typing forces you to know exactly what you're doing, and makes screwing up really easy, and the computer probably won't catch it for you. This is the opposite of what you want for beginning programmers.

ClokworkGremlin
Автор

I was classically trained in C and then decided to learn JavaScript. A dark time in my life.

Asasnol
Автор

[0:16] Can we just talk about how the green title screen in the background perfectly reacts to Tom's hand gestures? :D

AaronTheGerman
Автор

I love these IT themed videos, they make this noob understand much better what dark magic makes my pc work.

mirjanbouma