Company Name Starts with ...
#  A  B  C  D  E   F  G  H  I  J   K  L  M  N  O   P  Q  R  S  T   U  V  W  X  Y  Z

CTS C++ Code Interview Questions
Questions Answers Views Company eMail

What is the time complexity T(n) of the following program? a) int n, d, i, j; cin >> n; for (d=1; d<=n; d++) for (i=1; i<=d; i++) for (j=1; j<=n; j += n/10) cout << d << " " << i << " " << j << endl; b) void main() { int n, s, t; cin >> n; for (s = 1; s <= n/4; s++) {t = s; while (t >= 1) { cout << s << " " << t << endl; t--; } } } c) void main() { int n, r, s, t; cin >> n; for (r = 2; r <= n; r = r * 2) for (s = 1; s <= n/4; s++) { t = s; while (t >= 1) { cout << s << " " << t << endl; t--; } } }

3 7233

Find the maximum product of three numbers in an array? Eg. 9,5,1,2,3 Max product= 9*5*3= 135 The array can hav negative numbers also..

7 18897

Post New CTS C++ Code Interview Questions




CTS C++ Code Interview Questions


Un-Answered Questions

How to insert large data in mongodb?

1


Is it possible to change the warehouse after booking the sales order, if yes how to de allocate the items booked in previous warehouse?

106


How to use values from other tables in update statements using oracle?

82


what is Fault level? why it is calculated? how will u decide same for our plant?

998


What technique can be employed to compare two strings?

90






what are the vmware environment can be monitored by using vmware vi agent?

94


silt%= silt volume/ silt+sand volume is this right?

918


Explain the way messaging works in objective-c?

1


Mention the command to stop repl in node.js?

13


How many types of normalization? What is the use of it?

124


What is the meaning of linux shell and shell script?

110


What is detergent?

1


Wht do we use directive?

71


What is Activity diagram in UML?

121


What is shared memory in os?

66