--%>

Explain Method overriding

Method overriding: It is a method stated in a super class might be overridden by a method of similar name stated in a sub class. The two methods should have similar name and number and types of formal arguments. Any checked exception thrown by sub-class version should match the type of one thrown by the super class version, or be a sub-class of this exception. Though, the sub-class version does not encompass to throw any exceptions which are thrown by the super class version. This is significant to distinguish between method overloading and method overriding. Overloaded methods have similar names; however differ in their formal arguments.

   Related Questions in Programming Languages

  • Q : What is First in-first out First in,

    First in, first out: It is FIFO semantics of the queue data structure. Items are eliminated in the order in which they arrived in the queue; therefore older items are always eliminated before newer ones.

  • Q : Use of Macros used in windows-dot-h

    What is the use of Macros used in <windows.h> header files?

  • Q : Explain the purpose of using XML

    Explain the purpose of using XML.

  • Q : Learning File system with operations

    Program 1. Purpose of this assignment is to learn to work with files.Assignment: The file, data.txt, is provided on the class website. Each line of the file consists of a binary operator followed by two operands. Your program wi

  • Q : Define Number of Interleavings Number

    Number of Interleavings: Besides the raw number of threads, the state space is affected by the number of potential interleavings of these threads. While there exist automated techniques (partial-order reduction) to reduce these interleavings, most mod

  • Q : Define the term Garbage collector

    Garbage collector: It is a daemon thread which recycles objects to which there are no extant references in a program.

  • Q : Examples for 8 -16 - 32 bit

    Normal 0 false false

  • Q : Define the term Top level class Define

    Define the term Top level class: It is a class defined either at outermost level of a package or the static nested class.

  • Q : Define Single line comment Single line

    Single line comment: A comment is in the form:     // this line will be avoided by the compiler.

  • Q : Write a program using simple loop

    Objective:  The purpose of this problem is to gain experience with the principles necessary to write a program using simple loop, decision processing, counters and accumulators Save the Barns, a bi-partisan po