Narrowing cast: An explicit cast from a larger type to a smaller type, such as (int) myDouble, which truncates.
How to apply it: Predict truncation when casting double to int; (int) 9.99 evaluates to 9, not 10.
Course: AP Computer Science A · Unit: Primitive Types
Practice questions about Narrowing cast on AimFive — get rubric-based feedback showing exactly which points you earned.
AP and Advanced Placement are trademarks of College Board. AimFive is not affiliated with or endorsed by College Board.