Programming in Modern C++ Week 10 Assignment Answers
Are you looking for the NPTEL Programming in Modern C++ Week 10 Assignment Answers? You’ve come to the right place! This resource provides comprehensive solutions to all the questions from the Week 10 assignment, helping you navigate through the complexities of modern C++ programming.
Table of Contents
Programming in Modern C++ Week 10 Assignment Answers (Jan-Apr 2025)
Course Link: Click Here
1) Identify the appropriate option/s to fill in the blank at LINE-I such that output becomes B B
a) auto
b) auto&
c) decltype(rn)
d) decltype(n)
2) Identify the appropriate option/s to fill in the blank at LINE-I such that output becomes i 2.
a) auto foobar(Ut op) -> decltype(op())
b) auto foobar(U& op)
c) auto& foobar(U& op)
d) decltype(auto) foobar(Ut op)
3) Identify the appropriate option that presents all correct output/errors for the following instantiations of CustList class:
CustList c{3.1, 4.5, 6.5};CustList c(3.1, 4.5, 6.5);CustList c{3, 4.5f, 6.5};CustList c{3, 4.5, 6};
a) LINE-I
b) LINE-2
c) LINE-3
d) LINE-4
4) Which of the following line/s generate/s a compiler error?
a) LINE-I
b) LINE-2
c) LINE-3
d) LINE-4
5) Which of the following lines generate/s a compiler error?
a) LINE-I
b) LINE-2
c) LINE-3
d) LINE-4
6) Identify the appropriate option to fill in the blanks at LINE-I and LINE-2 such that the output becomes size (in bytes) : 1024.
a)
b)
c)
d)
7) Identify the correct option about the program above.
a) It generates output as 2 3 0 3
b) It generates output as 2 3 -1 2
c) It generates output as 2 3 -1 3
d) The program gets terminated since a function that is declared noexcept throws an exception
8) Identify the line/s that generate/s a compiler error.
a) LINE-I
b) LINE-2
c) LINE-3
d) LINE-4
9) What will be the output?
a)#1 #5 #4 #3
b)#1 #1 #5 #4 #3
c) #1 #3 #2 #3
d) #1 #1 #5 #2 #3
Programming in Modern C++ Week 10 Assignment Answers
For answers to others Nptel courses, please refer to this link: NPTEL Assignment