1. What is type inference in Kotlin?
Kotlin has powerful type inference that automatically determines variable types from their initialization values, allowing you to omit explicit type declarations in most cases while maintaining static type safety. For example, val name equals John automatically infers String type without writing val name colon String. This reduces boilerplate while keeping type safety, and the compiler can infer types for variables, function return types, and generic type parameters. However, you can still explicitly declare types for clarity or when the inferred type is not what you want.