1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
yaroslaw [1]
4 years ago
8

The scope of a variable declared inside of a function is:

Computers and Technology
1 answer:
Hatshy [7]4 years ago
7 0

Answer:

a

Explanation:

The variable declared is local within that function that is the declared variable is accessible inside that block itself, it cannot be accessible outside the given function.

ex - void add()

{

int a=10,  b=20 , c ;

c = a + b ;

cout << c ;

}

int main()

{

cout << "value for c is :"<< c ;

return 0;

}

Here inside the add function variable a, b,c are declared and initialized inside the function.

You might be interested in
)the number of levels in a tree is called
Nadya [2.5K]

Answer:

(D) Height

Explanation:

The number of levels in a tree is called height of that tree.The number of levels are always equal to the height of the tree.The height of the tree is the nodes between the root node and the farthest leaf node both inclusive.If the farthest leaf is at nth level then the height of the tree will be n.

5 0
3 years ago
Which of the following is the best description of an ip address?
Zinaida [17]
Send picture please
4 0
3 years ago
What is your favourite video game??​
Dmitry_Shevchenko [17]

In my opinion is Ghost Recon Wildlands ( Not so popular, but fun), or Rainbow Six Siege

6 0
3 years ago
Read 2 more answers
The point of (18 ,0) lies on​
zysi [14]
This point lies on the x value
4 0
3 years ago
Read 2 more answers
Write, compile, and test the MovieQuoteInfo class so that it displays your favorite movie quote, the movie it comes from, the ch
Irina18 [472]

Using the knowledge of computational language in JAVA it is possible to write a code that removes your favorite phrase from the movie. It consists of two classes in which one is driver code to test the MovieQuoteInfo class.

<h3>Writing code in JAVA:</h3>

<em>public class MovieQuoteInfo { //definition of MovieQuoteInfo class </em>

<em> //All the instance variables marked as private </em>

<em> private String quote;</em>

<em> private String saidBy;</em>

<em> private String movieName;</em>

<em> private int year;</em>

<em> public MovieQuoteInfo(String quote, String saidBy, String movieName, int year) { //parameterized constructor </em>

<em>  super();</em>

<em>  this.quote = quote;</em>

<em>  this.saidBy = saidBy;</em>

<em>  this.movieName = movieName;</em>

<em>  this.year = year;</em>

<em> }</em>

<em> //getters and setters </em>

<em> public String getQuote() {</em>

<em>  return quote;</em>

<em> }</em>

<em> public void setQuote(String quote) {</em>

<em>  this.quote = quote;</em>

<em> }</em>

<em> public String getSaidBy() {</em>

<em>  return saidBy;</em>

<em> }</em>

<em> public void setSaidBy(String saidBy) {</em>

<em>  this.saidBy = saidBy;</em>

<em> }</em>

<em> public String getMovieName() {</em>

<em>  return movieName;</em>

<em> }</em>

<em> public void setMovieName(String movieName) {</em>

<em>  this.movieName = movieName;</em>

<em> }</em>

<em> public int getYear() {</em>

<em>  return year;</em>

<em> }</em>

<em> public void setYear(int year) {</em>

<em>  this.year = year;</em>

<em> }</em>

<em> //overriden toString() to print the formatted data</em>

<em> public String toString() {</em>

<em>  String s = quote+",\n";</em>

<em>  s+="said by "+this.saidBy+"\n";</em>

<em>  s+="in the movie "+this.movieName+"\n";</em>

<em>  s+="in "+this.year+".";</em>

<em>  return s;</em>

<em> }</em>

<em>}</em>

<em>Driver.java</em>

<em>public class Driver { //driver code to test the MovieQuoteInfo class</em>

<em> public static void main(String[] args) {</em>

<em>  MovieQuoteInfo quote1 = new MovieQuoteInfo("Rosebud", "Charles Foster Kane", "Citizen Kane", 1941);//Create an object of MovieQuoteInfo class</em>

<em>  System.out.println(quote1); //print its details </em>

<em> }</em>

<em>}</em>

See more about JAVA at brainly.com/question/12975450

#SPJ1

7 0
2 years ago
Other questions:
  • An independent frame that holds a program, document, or folder contents in windows 7 is called a ____.
    11·1 answer
  • Multiple choice
    9·2 answers
  • Jeremy, a newly appointed assistant Director, is excited about his job. the director of the movie has assigned him the responsib
    6·1 answer
  • What is an efficient way to ensure that the code is working as per the acceptance criteria/business requirements? (1 correct ans
    11·2 answers
  • A network adapter, also called a ____ when it is in the form of an expansion card, is used to connect a computer to a network.
    13·1 answer
  • Asymmetric key encryption combined with the information provided by a. certificate authority allows unique identification of the
    8·1 answer
  • Which of the following is an advantage of computer usage? *
    10·1 answer
  • A. Fill in the blanks:
    6·1 answer
  • What are tasks performed by pascaline?​
    8·1 answer
  • List and describe the 3 tasks learners can do in a Technology classroom.
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!