منتديات الادب واللغة الانجليزية
أهلا و سهلا بكل الزوار ويا مية مرحبا
ارجو التسجيل لكي تستمتع وتستفيد من خدماتنا في المنتدى

انضم إلى المنتدى ، فالأمر سريع وسهل

منتديات الادب واللغة الانجليزية
أهلا و سهلا بكل الزوار ويا مية مرحبا
ارجو التسجيل لكي تستمتع وتستفيد من خدماتنا في المنتدى
منتديات الادب واللغة الانجليزية
هل تريد التفاعل مع هذه المساهمة؟ كل ما عليك هو إنشاء حساب جديد ببضع خطوات أو تسجيل الدخول للمتابعة.

Chapter 2 : Basic Elements of C++

اذهب الى الأسفل

27102010

مُساهمة 

Chapter 2 : Basic Elements of C++  Empty C++ MULTIPLE-CHOICE QUESTIONS - Chapter 3




CHAPTER 3 : Input/Output -- ED 2

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



Self-Tests
أسئلة اختيار من متعدد لمادة مهارات حاسوبية 2 مع الإجابات الصحيحة
MULTIPLE-CHOICE QUESTIONS
Chapter 3 : Input/Output i




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



1.After the program terminates, any values left in the input stream are __________. i

A: reused
B: updated
C: discarded
D: copied


Correct Answer :
Hidden:
C: discarded



2. Stream variables are called stream __________.

A: objects
B: place holders
C: values
D: items

Correct Answer :
Hidden:
A: objects


3. The extraction operator >> is binary and thus takes __________ operand(s).

A: no
B: one
C: two
D: three


Correct Answer :
Hidden:
C: two



4. In the cin.get statement, varChar which appears in parentheses following the function name, is called the argument or __________ of the function.

A: variable
B: parameter
C: value
D: content

Correct Answer :
Hidden:
B: parameter



5. I/O is a sequence of bytes called a __________.

A: sequence of bytes
B: group of bytes
C: word
D: stream of bytes

Correct Answer :
Hidden:
D: stream of bytes



6.When you want to process only partial data, you can use the stream function __________ to discard a portion of the input.

A: put
B: get
C: cin
D: ignore

Correct Answer :
Hidden:
D: ignore



7. The general syntax of the setprecision manipulator is __________.

A: precision(n)
B: setprec(n)
C: set precision(n)
D: setprecision(n)


Correct Answer :
Hidden:
D: setprecision(n)



8. Entering a char value into an int or double variable causes serious errors, called __________.

A: value errors
B: input failure
C: input errors
D: value failure


Correct Answer :
Hidden:
B: input failure



9.When there is an error, the input stream then enters a state called the __________ state.


A: error
B: problem
C: fail
D: misread

Correct Answer :
Hidden:
C: fail



10. Characters that consist of blanks and certain nonprintable characters, such as tabs and the newline character, are known as __________.

A: openspace
B: emptyspace
C: blankspace
D: whitespace


Correct Answer :
Hidden:
D: whitespace



11. The syntax to use the function peek is __________.

A: ch = istream.peek(Var);
B: ch = Varistream.peek();
C: ch = istreamVar.peek();
D: ch = istream.peek.Var();


Correct Answer :
Hidden:
C: ch = istreamVar.peek();



12. A sequence of characters from the computer to an output device is known as a(n) __________.

A: output stream
B: input stream
C: common output
D: common input


Correct Answer :
Hidden:
A: output stream



13. The stream function __________ lets you put the last character extracted from the input stream by the get function back into the input stream.

A: return
B: put
C: putback
D: peek

Correct Answer :
Hidden:
C: putback



14. The manipulator __________ is used to output the value of an expression in specific columns.

A: setw
B: set
C: setc
D: setn


Correct Answer :
Hidden:
A: setw



15. An expression such as pow(2,3) is called a __________.

A: function
B: program
C: function call
D: program call


Correct Answer :
Hidden:
C: function call



16. You can use the stream function __________ to restore the input stream to a working state.

A: restore
B: fix
C: update
D: clear


Correct Answer :
Hidden:
D: clear



17. A decimal number, possibly preceded by a (+ or -) sign, is valid input for which simple data type?


A: char
B: int
C: double
D: both b and c


Correct Answer :
Hidden:
D: both b and c



18. The function peek has __________ parentheses.

A: open
B: empty
C: filled
D: two sets of


Correct Answer :
Hidden:
B: empty



19. A __________ is either an input stream variable or an output stream variable.

A: function variable
B: user-defined variable
C: common output variable
D: stream variable


Correct Answer :
Hidden:
D: stream variable



20. Which stream function looks into the input stream and tells you what the next character is without removing it from the input stream?

A: return
B: put
C: putback
D: peek


Correct Answer :
Hidden:
D: peek


avatar
Admin
Admin

عدد المساهمات : 91
تاريخ التسجيل : 26/10/2010
الموقع : https://englishliterature.jordanforum.net

https://englishliterature.jordanforum.net

الرجوع الى أعلى الصفحة اذهب الى الأسفل

مُشاطرة هذه المقالة على: reddit

Chapter 2 : Basic Elements of C++ :: تعاليق

avatar

مُساهمة الأربعاء أكتوبر 27, 2010 3:08 am من طرف Admin

Chapter 2 : Basic Elements of C++ i




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



1. A set of rules, symbols, and special words that enable you to write code is known as __________. i

A: syntax rules
B: semantic rules
C: syntax
D: a programming language

Correct Answer :
Hidden:
D: a programming language



2. Which of the following is not a C++ special symbol?

A: <= i
B: == i
C: => i
D: != i

Correct Answer :
Hidden:
C: =>


3. Which of the following is not a legal identifier?

A: first
B: conversion
C: payRate
D: 'primary

Correct Answer :
Hidden:
D: 'primary



4. An expression that evaluates to true or false is called a(n) __________ expression.

A: logical (Boolean)
B: int
C: char
D: data

Correct Answer :
Hidden:
A: logical (Boolean)



5. The ASCII character set has __________ values.

A: 64
B: 128
C: 256
D: 512

Correct Answer :
Hidden:
B: 128



6. A string containing no characters is called a(n) __________ or empty string.

A: open
B: blank
C: null
D: closed

Correct Answer :
Hidden:
C: null



7. An operator that has two operands is known as a __________ operator.

A: unary
B: binary
C: dual
D: mixed


Correct Answer :
Hidden:
B: binary



8. A memory location whose content may change during program execution is known as a(n) __________.
A: variable
B: place holder
C: location
D: execution location


Correct Answer :
Hidden:
A: variable



9. A C++ program is a collection of one or more subprograms, called __________.

A: functions
B: statements
C: objects
D: parameters

Correct Answer :
Hidden:
A: functions



10. What tells you which statements (instructions) are legal, or accepted by the programming language, and which are not?

A: semantic rules
B: syntax rules
C: programming rules
D: language rules


Correct Answer :
Hidden:
B: syntax rules



11. A language used to describe the syntax rules is known as a(n) __________.

A: codelanguage
B: metalanguage
C: descriptive language
D: describer language


Correct Answer :
Hidden:
B: metalanguage



12. The letters that make up a reserved word are always __________.

A: lowercase
B: uppercase
C: camel case
D: capcase


Correct Answer :
Hidden:
A: lowercase



13. Which is a data type that deals with integers, or numbers without a decimal part?

A: integral
B: floating-point
C: enumeration type
D: numeric

Correct Answer :
Hidden:
A: integral



14. The collating sequence is used when you __________ characters.
A: create
B: compare
C: combine
D: count


Correct Answer :
Hidden:
B: compare



15. The maximum number of significant digits is called the __________.

A: significance
B: position
C: location
D: precision


Correct Answer :
Hidden:
D: precision



16. Every character in a string has a relative __________ in the string.

A: position
B: hierarchy
C: importance
D: area

Correct Answer :
Hidden:
A: position



17. An expression that has operands of different data types is called a __________ expression.

A: unary
B: binary
C: dual
D: mixed

Correct Answer :
Hidden:
D: mixed



18. Tracing values through a sequence is called a(n) __________.

A: association
B: walkthrough
C: play out
D: enumeration


Correct Answer :
Hidden:
B: walkthrough



19. A(n) __________ is a collection of statements that when activated or executed, accomplishes something.

A: object
B: statement
C: parameter
D: subprogram

Correct Answer :
Hidden:
D: subprogram



20. Which rules determine the meaning of the instructions?

A: semantic rules
B: syntax rules
C: programming rules
D: language rules


Correct Answer :
Hidden:
A: semantic rules



الرجوع الى أعلى الصفحة اذهب الى الأسفل

سعد الدهيمي

مُساهمة الأحد فبراير 27, 2011 6:59 am من طرف سعد الدهيمي

شكرااااااااا يا أدمن على الاسئلة واجوبتها
وان شاء نقرأها بعد قليل على روقان
تحياااااااااتي

الرجوع الى أعلى الصفحة اذهب الى الأسفل

Master

مُساهمة الأحد فبراير 27, 2011 3:07 pm من طرف Master

welcome

الرجوع الى أعلى الصفحة اذهب الى الأسفل

الرجوع الى أعلى الصفحة

- مواضيع مماثلة

 
صلاحيات هذا المنتدى:
لاتستطيع الرد على المواضيع في هذا المنتدى