Can’t find an answer?

Can’t find an answer?

Ask us to get the answer

  • This forum has 80 topics.

Select the statements that are true about default and copy constructors in C++:

  1. Compiler doesn’t create a default constructor if the user writes any constructor except the copy constructor.
  2. Compiler creates a copy constructor if the user doesn’t write its own copy constructor.
  3. Compiler doesn’t create a default constructor if the user writes any constructor even if it is copy constructor.

(A) 1 and 2
(B) Only 3
(C) Only 2
(D) 2 and 3

How does DHCP server dynamically assigns IP address to requesting host?
(A) Dynamically, IP address is leased to requesting host for finite lease duration by DHCP server.
(B) Dynamically IP address is leased to requesting host for an Infinite lease duration by DHCP server.
(C) Dynamically, Static IP address is leased to requesting host for a finite lease duration by DHCP server.
(D) Statically, dynamic IP address is leased to requesting host for an Infinite lease duration by DHCP server.

What is the probability of getting a Saturday in a Week?
(A) 1
(B) 1/7
(C) 1/2
(D) 2/7
(E) 0

What will be the remainder when 7100 is divided by 5?
(A) 0
(B) 1
(C) 2
(D) 3

A C++ class can contain a member of SELF type if the member is.

  1. Static
  2. Pointer
  3. Non-static

(A) Only 3
(B) Both 2 and 3
(C) Both 1 and 2
(D) Only 1

In an experiment, one red dice and one black dice(both are fair) are rolled. What is the probability that,

  1. The number on black dice will divide the number on red dice.
  2. Number on black dice is multiple of the number on red dice.

(A) 22 / 36 and 14 / 36 respectively

(B) 12 / 36 and 18 / 36 respectively
(C) 14 / 36 and 14 /36 respectively
(D) 6 / 36 and 8 / 36 respectively

What will be the output of the below C++ program?




#include<iostream>
using namespace std;
int main()
{
int a[] = {10,20,30,40,50};
cout<<(*(&a+1)-a);
return 0;
}

(A) 10
(B) 0x7ffc7185f754
(C) 50
(D) 5

The value of the expression 100i=2 1/logi100! is:
(A) 0.01
(B) 0.1
(C) 1
(D) 10

x, 17, 3x – y2 – 2 and 3x + y2 – 30 are four consecutive terms of an increasing arithmetic sequence. The sum of the four numbers is divisible by:
(A) 2
(B) 3
(C) 5
(D) 7

log1010 + log10102 + … + log1010n
(A) \n^2 + 1
(B) \n^2- 1
(C) \[(n^2+ n)/2] * [(n(n+1))/3]
(D) \(n^2+ n)/2

Viewing 15 topics - 46 through 60 (of 80 total)

1 2 3 4 5 6
  • You must be logged in to create new topics.