Hacker News new | past | comments | ask | show | jobs | submit login

Dynamic typing can forbid the latter (at runtime), but it's implementation dependent. There's a further distinction, Latent typing, which is where types are associated with values rather than variables.

But a dynamic language can have types associated with variables, and it can forbid changing those types after their types have been checked the first time.




> But a dynamic language can have types associated with variables, and it can forbid changing those types after their types have been checked the first time.

So, like C++ with `auto`?


`auto` is still using static typing, and is a tool for type inference. A dynamically typed version might look equivalent but would behave differently, failing at runtime rather than compile time.




Consider applying for YC's Summer 2025 batch! Applications are open till May 13

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: