Latest Activity In Study Groups

Join Your Study Groups

VU Past Papers, MCQs and More

We non-commercial site working hard since 2009 to facilitate learning Read More. We can't keep up without your support. Donate.


CS504 Software Engneering - I Online quiz#4 solution and discussion due date 19-02-2015 to 20-02-2015

Views: 5391

Replies to This Discussion

cs504

Attachments:

In order to make a code more portable, Instead of using vendor specific language extensions, use _______ as much as possible

  • STL (correct)
  • ANSI
  • ISO
  • CMMI




Constant values used in the program are called_________.

  • Real Numbers
  • Magic numbers
  • Constant numbers  (c)
  • Positive numbers 


Some bit field members are stored: I) left to right II) right to left III) in circular array

  • only (I) is true
  • Only (II) is true
  • Both (I) and (II) are true  (c)
  • All of the options (I, II and III) are true




if (!(block < activeBlock)) is equvivalent to:

  • if ((block < activeBlock))
  • if ((block == activeBlock))
  • if ((block >= activeBlock))     (c)
  • None of the given




Identifier names also play a significant role in enhancing the -------- of a program.

  • Writ ability
  • Readability    (c)
  • Reliability
  • All of given 


"is" prefix should be used for------ variables and methods.

  • General
  • Boolean    (c)
  • Constant
  • None of given 




It ensures that a class only has one instance and provides a global point of access to it.

  • Singleton Pattern    (c)
  • Observer Pattern
  • Real Pattern
  • None of the given


When a small set of functions (which use each other) is so overwhelmingly the bottleneck, there are two alternatives:

  • use a better algorithm OR re-write the code    (c)
  • debug the code OR place assertions in code
  • remove the functions OR add more functions
  • changed programming language OR compiler at least




One of the main reasons to make functions is ________

  • Reliability
  • Reusability     (c)
  • Maintainability
  • Effeciency




Bit fields are a convenient way to express many difficult operations. However, bit fields suffer from one problem

  • Lack of usability
  • Lack of security
  • Lack of performance
  • Lack of portability      (c)




1:      Switch statement is equal to…………………statement.

                               if-else                    (ANS)

2:       ……..provides a unified interface to a set of interfaces in a sub-system

                           Façade pattern              (ANS)

3:-        using proper parenthesis normally makes the code

               All of the given options               (ANS)

4:          ………….was the first pure object Oriented language in which observer pattern was used in implementing its Model View Controller pattern

                      Smalltalk                     (ANS)

5:-       which one is correct?

Double total=0.5;       (ANS)

Double total=.5;

Double total=.50;

All of the given              

                   

6:-    Exception handling is a powerful technique that separates error-handling code from …….code

                                 Normal                    (ANS)

7:      …………..and………….are important short circuiting logical operators. a. AND, b. OR , c. NOT, d. NOR,

                    A&b               (ANS)

8:   some bit field members are stored:1)Left to right  2) Right to left in the circular array.

                       both (1) and (2) is true     (ANS)

9: One of the main reasons to make function is ……..

                            Reusability        (ANS)  

10: if (!(block < active  Block)) is equvivalent to:

                         if ((block >= active  Block))         (ANS)  

11:-    In order to make a code more portable, Instead of using vendor specific language extensions, use _______ as much as possible

  • STL            (ANS)

 

  • ANSI
  • ISO
  • CMMI

 

12:-    Constant values used in the program are called_________.

  • Real Numbers
  • Magic numbers
  • Constant numbers        (ANS)
  • Positive numbers 

Some bit field members are stored: I) left to right II) right to left III) in circular array

  • only (I) is true
  • Only (II) is true
  • Both (I) and (II) are true
  • All of the options (I, II and III) are true

 

Both (I) and (II) are true             (ANS)

 

Identifier names also play a significant role in enhancing the -------- of a program.

  • Writ ability
  • Readability
  • Reliability            (ANS)
  • All of given 

 

"is" prefix should be used for------ variables and methods.

  • General
  • Boolean               (ANS)
  • Constant
  • None of given 

It ensures that a class only has one instance and provides a global point of access to it.

  • Singleton Pattern
  • Observer Pattern
  • Real Pattern
  • None of the given


    • Singleton Pattern      (ANS)

 

 

When a small set of functions (which use each other) is so overwhelmingly the bottleneck, there are two alternatives:

 

  • use a better algorithm OR re-write the code           (ANS)
  • debug the code OR place assertions in code
  • remove the functions OR add more functions
  • changed programming language OR compiler at least

 

 

Bit fields are a convenient way to express many difficult operations. However, bit fields suffer from one problem

  • Lack of usability
  • Lack of security
  • Lack of performance
  • Lack of portability


    • Lack of portability      (ANS)

 

 

One of the main reasons to make functions is ________

  • Reliability
  • Reusability                          (ANS)
  • Maintainability
  • Effeciency

 

In the switch statement, cases should always end with a statement

                        Break                   (ANS)

 

Str=0;// str is string which rewritten from of above line of code is more in line with the self-documentation philosophy than the code above

  

               Str=NULL;          (ANS)

 

In case of header files,construction is to avoid…..errors. the construction should appear in the top of the file (before the file header);

              Complation                  (ANS)

 

The idea behind exception handling is to raise some error flag every time………………..

                   Something goes wrong               (ANS)

 

   The form for (;;)should be used for

                  Empty loop            (ANS)

 

Bit fields allow the packing  of data in a structure.using Bit fields we can:

                 Read 9 bit integers            (ANS)

 

  C++ header files should have the extension…….source files can have the extension……

           .h and .cpp                 (ANS)

 


RSS

Looking For Something? Search Below

VIP Member Badge & Others

How to Get This Badge at Your Profile DP

------------------------------------

Management: Admins ::: Moderators

Other Awards Badges List Moderators Group

© 2021   Created by + M.Tariq Malik.   Powered by

Promote Us  |  Report an Issue  |  Privacy Policy  |  Terms of Service