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
Ilya [14]
3 years ago
10

.What is overriding? Which keyword is needed to implement overriding?

Computers and Technology
1 answer:
Eduardwww [97]3 years ago
6 0

Answer:

overriding is defining a function in derived class  with same name which is already exist in  base class.

Explanation:

Override key word is used in DotNet for overriding .It differes from language to language.In c++ no keyword is required for overriding.

#include<iostream.h>

public class  BaseClass

{

public :

void print(){

cout<<"print in base class";

}

}

public class DerivedClass : public BaseClass

{

public :

void print(){

cout<<"print in derived class";

}

}

void main(){

BaseClass b=new BaseClass();

b.print();

DerivedClass d=new DerivedClass();

d.print()

}

You might be interested in
Please answer the following essay question:
MArishka [77]
Advertising is a paid promotion that uses strategic planning to target a certain audience. The seven functions of marketing is promotion, selling, product management, marketing information management, pricing, financing, and distribution. Usually you see common advertising such as digital ads, billboards, newspapers, flyers, and more. Advertising can spread awareness, popularize a brand, increase customer demand, and company profits. Advertising is necessary for most- if not all- companies including media outlets, the television industry, search engine companies, and social media websites.
8 0
3 years ago
Write a program that takes in a positive integer as input, and outputs a string of 1's and 0's representing the integer in binar
Mashcka [7]

Answer:

Following are the code to this question:

def binarynumber(num):#defining a method binarynumber that accepts a parameter num

   x=""#defining a string variable x

   if (num!=0):#defining if condition to check number not equal to 0

       while (num>=1):#defining a loop that check value is grater then equal to one

           if (num %2==0):#defining if condition to check num is even

               x=x+"0" #add string value 0 in num variable

               num=num/2 #divide the value by 2

           else:#defining else block

               x=x+"1"#add string value 1 in num variable

               num=(num-1)/2#first subtract 1 into num variable then divide the value by 2

   else:

       x="0"#assign string value 0 in num variable  

   return "".join(reversed(x))#return value

num = int (input ("Enter any number: "))#defining num variable that input the integer value

print (binarynumber(num))#using print method to call method binarynumber with passing num parameter

Output:

Enter any number: 12

1100

Explanation:

  • In the above python code a method "binarynumber" is declared, in which the "num" variable passes as the parameter inside the method a string variable "x" is declared that stores all converted values.
  • Inside the method and if the block is declared that checks number value is not equal to 0 if this condition is false then it will add string value and reverse its value.
  • Or if the condition is true it defines a while loop that calculates the given number binary digits and returns its value.
  • At the last step, the num variable is declared that inputs the integer value from the user end and calls the method by using the print method.    
6 0
4 years ago
Dell, previously the world’s number one PC manufacturer, has seen its market share shrink because of rivals copying its value ch
stepladder [879]

Answer:

A) underscore the importance of continually assessing a firm's strategic position among changing market conditions.

Explanation:

Dell computers believed their leadership position would last forever and forgot the basic rule that it is very hard to reach the top, but it's even harder to stay there.

The market conditions changed since globalization made the world smaller, increasing the potential customers but also increasing competition. Dell wasn't able to revise their strategic position and adapt it to changing markets. A company's strategic position refers to how its strategy deals with changing:

  • environments,
  • competition,
  • resources,
  • stakeholders' expectations.

The same thing happened to General Motors, that once used to be the largest and most profitable car manufacturer in the world, and then went bankrupt. It is still under a lot of financial stress and is continuously losing market share in the US and around the world.

5 0
4 years ago
Why does dns use udp instead of tcp? if a dns packet is lost, there is no automatic recovery. what are the consequences?
inysia [295]
<span>If a DNS packet using UDP is lost this problem must be handled at the application layer. If an answer is not received after some period of time the specific application may choose to resend the DNS query. I can go much more into detail but this should answer your question. If you need more detail just ask.</span>
6 0
3 years ago
As technology advances, does it require science and math applications? Provide 1 to 3 examples.
Rina8888 [55]

Less because computers can do almost everything for you . ... Yes it is more efficient because they are making more things that computers and cell phones can do for you.

8 0
3 years ago
Other questions:
  • Which company has experienced censorship in China?
    13·2 answers
  • This was a quiz that I submitted earlier in the semester but I had not received full points due to a coding mistake. Below, I wi
    14·1 answer
  • Antonio’s computer is hung up. which trio of keys should he press to restart his computer?
    7·2 answers
  • You have successfully compiled the file Hi.java, how do you run the corresponding program from the command line?
    7·1 answer
  • How can you print a mailing label in word
    13·1 answer
  • You can change the color of the value of a cell or the background color of the cell but not both.
    5·2 answers
  • In 2-3 sentences, explain to another student why shortcuts are beneficial. Include details about shortcuts that you have used.
    10·2 answers
  • All the read/write heads a hard disk are controlled by a(n) ____ which moves the read/write heads across the disk surfaces in un
    13·1 answer
  • Which file types have exe and png as their extensions?
    10·1 answer
  • A classic game, Wario Land, has an invincible main character who reacts to the environment in order to solve puzzles. So, for ex
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!