Concepts of Programming Languages (11th Edition)
11th Edition
ISBN: 9780133943023
Author: Robert W. Sebesta
Publisher: PEARSON
expand_more
expand_more
format_list_bulleted
Question
Chapter 6, Problem 20PS
Program Plan Intro
Static type checking:
- A language is statically-typed if the type of a variable is known at compile time.
- It allows many type errors to be caught early in the development cycle.
- Static typing usually results in compiled code which executes more quickly because when the compiler knows the exact data types which are in use, it can produce optimized machine code.
- It evaluate only the type information which can be determined at compile time, but are able to verify that the checked conditions hold for all possible executions of the program, which eliminated the need to repeat type checks every time the program is executed.
Dynamic type checking:
- It is the process of verifying the type safety of a program at runtime.
- Most type-safe languages include some form of dynamic type checking, even if they also have a static type checker.
- The reason for this is that many useful features or properties are difficult or impossible to verify statically.
Expert Solution & Answer
Want to see the full answer?
Check out a sample textbook solutionStudents have asked these similar questions
In what way is static type checking better than dynamic type checking?
Where does static type checking differ from dynamic type checking?
To what extent does static type checking differ from its dynamic counterpart?
Chapter 6 Solutions
Concepts of Programming Languages (11th Edition)
Knowledge Booster
Similar questions
- What distinguishes automated type conversion from type casting? What are the type promotion rules in Java expressions?arrow_forwardWhat is the difference between type equivalence and type compatibility?arrow_forwardWhat is the difference between the value-type variables and reference-type variables in terms of garbage collection?arrow_forward
- What does "type checking" mean? Explain the differences between static Lype checking and dynamic type checking, as well as the relative benefits of each.arrow_forward2B. What is the difference between automatic type conversion and type casting? What are the type promotion rules in Java expressions?arrow_forwardWhatis meant by implicit and explicit type conversion?arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- C++ for Engineers and ScientistsComputer ScienceISBN:9781133187844Author:Bronson, Gary J.Publisher:Course Technology PtrEBK JAVA PROGRAMMINGComputer ScienceISBN:9781337671385Author:FARRELLPublisher:CENGAGE LEARNING - CONSIGNMENT
C++ for Engineers and Scientists
Computer Science
ISBN:9781133187844
Author:Bronson, Gary J.
Publisher:Course Technology Ptr
EBK JAVA PROGRAMMING
Computer Science
ISBN:9781337671385
Author:FARRELL
Publisher:CENGAGE LEARNING - CONSIGNMENT