Home / MCQ Bank / Computer
Computer Interfaces And Abstract Classes Difficulty: Medium

Given the following piece of code: public interface Guard{ void doYourJob(); } abstract public class Dog implements Guard{ } which of the following statements is correct?

Select the correct option to test your answer:

More Computer Questions

What will be the output of the following C++ code? #include <iostream> using namespace std; #include <cstdlib> #include <exception> void Funct() { cout << "Funct() was called by terminate()." << endl; exit(0); } int main() { try { set_terminate(Funct); throw "Out of memory!"; } catch(int) { cout << "Integer exception raised." << endl; } return 0; } A class member declared protected becomes member of subclass of which type? What will be the output of the following C code? #include <stdio.h> void main() { int k = 4; int *const p = &k; int r = 3; p = &r; printf("%d", p); } What is the priority of a null node? In a graph with weighted edges, what does the term "relaxation" refer to in shortest path algorithms?