No chatgpt write the answer for below question

below r the document

Save Time On Research and Writing
Hire a Pro to Write You a 100% Plagiarism-Free Paper.
Get My Paper

Homework 4. Variables and Data Types
Chapter 5:
1.Assume the following Ada program was compiled and executed.
procedure Main is
X: Integer;
procedure Sub1 is
begin — of Sub1
Put(X);
end;
procedure Sub2 is
X: Integer;
begin — of Sub2
X := 10;
Sub1;
end;
begin — of Main
X := 5;
Sub2
end;
a) Using static scoping rules, what is the value of X is
printed in procedure Sub1?
b) Under dynamic-scoping rules, what value of X is printed in
procedure Sub1?
Chapter 6:
2. There are five different types of arrays discussed in class:
static, fixed stack-dynamic, fixed heap-dynamic, and heapdynamic. Identify the categories of arrays at positions 1, 2,
3, and 4.
1
2
3
4
3. Given all the languages that you know, produce a list of data
types in these languages.
4. What are the advantages of user-defined enumeration types?
5. List two design issues for arrays.
6. What is the structure of an associative array?
7. List one aspect that record and union are the same and one
aspect that they are different.
8. Are the tuples of Python mutable?
9. Java is a static-typed language.
language” mean?
What does “static-typed
10. Compared with C, Java is a strong-typed language. What does
“strong-typed language” mean?
11. What is a compatible type?
12.
What is name type equivalence?
13. How do you evaluate a programming language by its data
types?

Still stressed with your coursework?
Get quality coursework help from an expert!