Faisalabad Board 2017
Computer Science
(Objective Type)
Inter (Part-2)
Note: Four possible answers A, B, C and D to each question are given. The choice which you think is correct that circle in front that question with Marker or Pen ink. 'Lining or filling two or more circles 'will result in zero mat k in that question. Write the letter A, B. C or D in the column. (Write correct "option) against each question also. If there k a contradiction in the bubble and hand written answer, bubble option will be considered correct.
- Which is used to indicate characteristics of an object:
- Relationship
- Cardinality
- Modality
- Attribute
- Which is also called control key:
- Sort key
- Composite key
- Candidate key
- Primary key
- The process of arranging data in a logical sequence is called
- Sorting
- Summarizing
- Clouting
- Classifying
- How many layout of report are there?
- 2
- 3
- 4
- 5
- Which view is used to add, edit or delete record from table?
- Record view
- Datasheet view
- Design view
- Which object is used to store data in database:
- Macro
- Table
- Form
- Report
C-LANGUAGE
- Conditional operator is an alternative of:
- If
- Nested if
- If else
- Switch - case
- What operators are used to join two or more conditions?
- Relational
- Logical
- Assignment
- Comparison
- How many variables can be used in one print function?
- One
- Two
- Ten
- Many
- Which is a valid character constant?
- A
- “Hello”
- ‘6’
- =
- Period
- Comma
- Colon
- Semi colon
- An array subscript should be:
- Float
- Double
- Int
- Real
- Global variables are create in:
- ROM
- RAM
- HARD DISK
- Cache
- The loop that never ends is called:
- Infinite loop
- Running loop
- Continuous loop
- Nested loop
- This statement cause the loop to terminate early:
- Break
- Terminate
- Exit
- End
SUBJECTIVE PART
SECTION B
2. Write short answers to any six parts from the following:
- Define program file.
- Write any two objectives of database management system
- Write the basic purpose of using views.
- Define an attribute. Give an example.
- How referential integrity can be achieved?
- Define partial dependency.
- List down any tow advantage of MS-Access.
- Write a query to display all records form a table employee.
- Write the use of columnar from in MS-Access
3. Write short answers to any eight parts of the following:
- What is #define directive?
- Describe delimiters.
- Define structure programming
- Differentiate between increment and decrement operators.
- How a variable is declared in C?
- State the purpose of escape sequence.
- Find the errors in the following piece of code:
# include (stdio.h)
VOID MAIN()
{ int a = 10;
Printf("%f",a);
}
- Trace the errors form the following piece of code:
Include<stdio.h>
Void main[]
{printf('Pakistan');
}T
- Trace output:
void main()
{ int a,b;
A = 10;
B = 12;
Int c = a+b;
Printf("c = %3d",--C);
}
4. Write short answer to any six parts.
- Why sentinel value is used in loop?
- What happens if break statement is missed in case block?
- Find errors:
Void main()
{
Int a-2
if(a = 1)
Printf("OK");
else
printf("Cancle");
gatch()
}
- Show output:
If(1 == 2)
Printf("Programming");
Else
If(2 == 1)
Printf("language")
- Show output
int I, a = 3;
for(i = 5; I>0;I--)
{
a = a+I;
printf("%d\t",a);
}
Section-III
Q 6. Convert into Do-While loop code:
int I = 1;
while( I < +10)
{
printf("a")
I - I + 1;
}
C-LANGUAGE
Note: Attempt and two question.
Q 7. Write basic structure of C program.
Q 8. Write a program in C-language that inputs temperature and display message according to following
Temperature |
Message |
Greater than 35 |
Hot day |
Between 25 and 35 (inclusive) |
Pleasant day |
Less than 25 |
Cool day |
Q 9. Define do- while loop? Explain its syntax with syntax, flowchart and example.