If a=5, b=6, c=7, b+=a%c*2. What is the final value of b?
The above line of the code gets executed using the C++ program, the output will give 10 as value of b at the prompt. It will process the b+=(5%7*2), as b values is already given as 6 then it will add, to the assigned value to the result got from the expression. if properly syntaxes and executed the program.
| Is This Answer Correct ? | 0 Yes | 0 No |
What is abstraction in oops?
143.what is oops principles?
what i oops concept, how many languages supports oops concept?
what is virtual destructor
Write A Program using Single and Multiple Inheritance.
#include <iostream> using namespace std; int main() { int a = 2; int c[5][5]; for (int x=0;x<5;x++) { for (int y=0;y<5;y++) { c[x][y] = x*y; } } cout << c[a][c[1][4]]; }
Write a C++ program without using any loop (if, for, while etc) to print prime numbers from 1 to 100 and 100 to 1 (Do not use 200 print statements!!!)
Describe these concepts: Polymorphism, Inheritance and Abstraction.
can we make game by using c
Can you name some types of inheritance?
create a class complex having real and imaginary part of a complex no. as a data member. overload the binary operators(+,- and *) to perform the operations on complex no. objects. overload binary operator using friend function.
2 Answers CTS, Delhi University,
What are virtual classes?