Concepts Of Programming Languages
12th Edition
ISBN: 9780134997186
Author: Sebesta, Robert W.
Publisher: Pearson,
expand_more
expand_more
format_list_bulleted
Expert Solution & Answer
Chapter 5, Problem 1RQ
Explanation of Solution
Names:
To identify an entity present in the program, strings of character are used and it is called as name.
Design issues for the name:
The primary design issues for the name are discussed below:
- Case sensitivity of the names.
- The design issue that rise with the case-sensitivity is that language constructs that looks similar must also contain the same meanings as defined.
- Reserved words or keywords are the special words of the language.
- Every
programming language contains own pre-defined keywords, reserved words. - The design issues will be in re-defining the key words which can be confusing and using the reserved words will be better choice in the language design.
- There will be a readability issue rather than the readability issue.
- Every
Some of the example of design issues that occur with the names:
While writing names of the identifier there are some of the naming rules that should be followed and below are some of the example design issues that occur with the names:
- The name of the identifier should not be as the name of the keyword that is predefined.
- Some of the keywords such “enum”, “static”, “class” cannot be used as the identifiers name.
- Constant that are defined should be present in the upper case.
- Constant variables that are defined to be final are considered as constant.
- For case sensitive programming language the case of the words plays a vital role that is proper usage of lower case and upper case is required.
- The variable “run”, “RUN” or “Run” will have different meaning for the case sensitive programming languages.
Want to see more full solutions like this?
Subscribe now to access step-by-step solutions to millions of textbook problems written by subject matter experts!
Students have asked these similar questions
Who designed the structures at Harvard?
What is Debugging utilized for when it comes to programming?
Explain the concept of reserved keywords in programming languages. How are these keywords protected from being used as identifiers, and why is it important?
Chapter 5 Solutions
Concepts Of Programming Languages
Ch. 5 - Prob. 1RQCh. 5 - Prob. 2RQCh. 5 - Prob. 3RQCh. 5 - Which category of C++ reference variables always...Ch. 5 - Prob. 5RQCh. 5 - Prob. 6RQCh. 5 - Prob. 7RQCh. 5 - Prob. 8RQCh. 5 - What are the advantages and disadvantages of...Ch. 5 - Prob. 10RQ
Ch. 5 - Prob. 11RQCh. 5 - Prob. 12RQCh. 5 - How is a reference to a nonlocal variable in a...Ch. 5 - What is the general problem with static scoping?Ch. 5 - What is the referencing environment of a...Ch. 5 - Prob. 16RQCh. 5 - What is a block?Ch. 5 - What is the purpose of the let constructs in...Ch. 5 - What is the difference between the names defined...Ch. 5 - Prob. 20RQCh. 5 - Prob. 21RQCh. 5 - What are the advantages of named constants?Ch. 5 - Which of the following identifier forms is most...Ch. 5 - Prob. 2PSCh. 5 - Write a simple assignment statement with one...Ch. 5 - Prob. 4PSCh. 5 - Describe a situation when a history-sensitive...Ch. 5 - Consider the following C program void fun (void) {...Ch. 5 - Consider the following skeletal C program: void...Ch. 5 - Which of the following identifier forms is most...Ch. 5 - Prob. 2PECh. 5 - Write a simple assignment statement with one...
Knowledge Booster
Similar questions
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Np Ms Office 365/Excel 2016 I NtermedComputer ScienceISBN:9781337508841Author:CareyPublisher:Cengage
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:9781337508841
Author:Carey
Publisher:Cengage