Computer Science
10th Class
OBJECTIVE (2022)
(1) Which operator is used for initializing?
(A) → (B) = (C) @ (D)?
(2) Which operator has highest precedence?
(A) / (B) = (C) > (D)!
(3) Which of the following is basic type of operator?
(A) Arithmetic operator (B) Relational operator (C) Cheek operator (D) Lineal operator
(4) How many types of control statement in C language?
(A) Five (B) Two (C) Three (D) Four
(5) Which is a election statement?
(A) Float (B) if-else (C) Array (D) Loop
(6) What is the output of the following code?
int a[4] ={8,7.6,5}.
Printf {‘%d”, a [3]};
(A) 5 (B) 6 (C) 7 (D) 8
(7) How many times the word ‘PUNJAB” will be printed using for loop?
for (int a = 0; a <6 ; a++),
printf (“PUNJAB”);
(A) 5 (B) 6 (C)7 (D) 8
(8)The print and scan are:
(A) Built-In functions (B) Control functions
(C) User defined functions (D) Commercial functions
(9) A function that does not return anything has return type:
(A) Null (B) nothing (C) switch (D) void
(I0) Multiple arguments passed to a function are separated by:
(A): (B); (C), (D).
SUBJECTIVE (2022)
Short Questions
(i) Write down any four keywords.
(ii) What is meant by character set?
(iii) How Int data typo can be declared?
(iv)What is the difference between == operator and ≠operator?
(v) What is the purpose of statement terminator?
(vi) What is use of assignment operator?
(vii) What is selection statement?
(viii) What will be the output of this code?
int I = 0;
if ( i<1 )
printf (‘OKAY’);
else
printf (”Bye”).
(ix) Draw a flowchart that shows the basic flow of if statement.
(x) Define Compound statement
(xi) What is an array?
(xii) How can you declare an ray in C-language?
(xiii) What Is meant by aerator In a loop?
(xiv) Write output of following code
for ( int I = 2; i < 7; i++ )
printf (” %d \ n”, i );
(xv) Write different types of function
(xvi) Write structure of function definition.
(xvii) Define return value of a function
(xviii) How does a fusion return a value?
Long Questions
- Write the events rules 4+2+2 of variable. Also explain the declaration and initialization of variable with examples 2 + 6 = 8
- What is meant by relational operators? Write detailed note on ‘sooner Operators With use in C-language Structure =4 Logic = 4.
- Write a program using FOR loop to print odd number from 1 to 19.
OBJECTIVE (2022)
- How many possible solutions are there for a problem?
(A) One
(B) Two
(C) Three
(D) Multiple
- GW-BASIC can operate in:
(A) One mode
(B) Two modes
(C) Three modes
(D) Several modes
- Which of the blowing statement temporarily stops the execution of program?
(A) BREAK
(B) END
(C) PAUSE
(D) STOP
- Which of the following cannot be used to exit from an error handing routine?
(A) RESUME
(B) RESUME NEXT
(C) END
(D) STOP
- Dimension statement uses the keyword:
(A) DMS
(B) DS
(C) DIM
(D) DM
- The output of a function INT (-5.7) is:
(A) -5
(B) -4
(C) -6
(D) 5
- TAN(x) =
(A) SIN(x) /COT(x)
(B) COT(x)
(C) COS(x) / SIN (x)
(D) SIN(x)/COS(x)
- Which function changes the way of displaying output in BASIC?
(A) SCREEN
(B) PRINT
(C) LEFT$
(D) ABS
- Which one options is not in Edit menu?
(A) Undo
(B) Redo
(C) Find
(D) Font
- Which key board short cut is used for print preview?
(A) Ctrl +P
(B) Ctrl+F12
(C) Alt +P
(D) Ctrl+F2
Objective (2021)
(1) How many possible solutions are there for a problem?
(A) One
(B) Two
(C) Three
(D) Multiple
(2) GW-BASIC can operate in:
(A) One mode
(B) Two modes
(C) Three modes
(D) Several modes
(3) The maximum length of a variable name in GW-BASIC is:
(A) 31
(B) 32
(C) 40
(D) 45
(4) Which of the following is not a logical operator?
(A) AND
(B) OR
(C) NOT
(D) NETHER
(5) FOR—NEXT is used to implement:
(A) Iteration
(B) Selection
(C) Sequence
(D) All these
(6) There are____ types of an array.
(A) 1
(B) 2
(c) 3
(D) 4
(7) The statement X (30) will reserve ___ memory locations.
(A) 29
(B) 30
(c) 34
(D) 40
(8) The output of a function INT (-5.7) is:
(A) -5
(B) -4
(C) -6
(D) 5
(9) The _____ function is used to convert ASCII codes to its character equivalent.
(A) CHAR$ ()
(B) CHR ()
(C) CHAR
(D) CHR$ ()
(10) Which function changes the way of displaying output in BASIC?
(A) SCREEN
(B) PRINT
(C) LEFT$
(D) ABS
SUBJECTIVE (2022)
Short Questions
- What is meant by syntax of programming language?
- How many types of errors can be in programming? Write names
- Write three characteristics of BASIC.
- Define variables in BASIC.
- Write the procedure of operation in GW-BASIC.
- Describe about indirect mode.
- What is meant by DIM-Statement?
- Differentiate between 1-D Array and 2-D May.
- Describe about printing two dimensional Array.
- Write the syntax of user-defined function.
- Describe the purpose of INT ( ) function.
- Differentiate between data file and program file.
- He Define GoTo statement.
- Define Text mode.
- What is Status BAR?
- How can you save a document in MS-Word?
- What is clipboard?
- How can you print a document in MS-Word?
Long Questions
- Write down the strategy for developing algorithm 4 + 4 and write an algorithm for baking a cake at home.
- Define Nested Loop. 2 + 3 + 3 Write purpose and syntax of For-Next and While-Wend Loop
2 + 3 + 3
- What is CIRCLE statement? Explain the syntax of CIRCLE statement with example.
OBJECTIVE (2022)
(1) For initialize a variable, we use_____ Operator.
(A) →
(B) =
(C) @
(D) ?
(2) getch ( )is used to take ______as input from the user.
(A) int
(B) float
(C) char
(D) printf
(3) Which of the following is a valid tine of code?
(A) int = 20;
(B) grade =’A’;;
(C) line = this is a tine;
(D) int=c
(4) Which of the following is the condition to check a is factor of c?
(A) a%c==0
(B) c%a==0
(C) a*c==0
(0) a+c==0
(5) Sequential control is the____control structure in C-language.
(A) Selection
(B) Repetition
(C) Relation
(D) Default
(6) Array elements are stored at____memory location.
(A) Contiguous
(B) Scattered
(C) Divided
(D) Add
(7) ______ part of for loop is executed first.
(A) Condition
(B) Body
(C) Initialization
(D) Increment/decrement
(8) The functions which are available in C Standard Library are called:
(A) user-defined
(B) Built-in
(C) Recursive
(D) Repetitive
(9) What will be the output of code?
Void main ( )
{
printf (“2”).
}
(A) 3
(B) 1
(C) 2
(D) 4
(10) Readability helps to__ the code.
(A) Save
(B) Modify
(C) Run
(D) Compile
SUBJECTIVE (2022)
Short Questions
- What is meant by programming environment?
- Write two rules for naming variables.
- Differentiate between “char” and “int”.
- Define logical operators.
- What is the use of format specifier in C-language?
- Differentiate between unary operators and binary operators.
- Define control statements.
- Why do we need selection statements?
- Identify the errors in the following code:if(x ⪰10)printf (“Good”):
- Write the structure of if statement.
- Write the example of the declaration of a float type array that holds marks of five students.
- Define data structure.
- Define loop.
- Write output of following code:for (int i = 0; i< 2; i++)printf (“Pakistan\n”),
- What is divide and conquer rule?
- Define function.
- Write two advantages of function.
- Differentiate between argument and parameter.
Long Questions
- What is meant by comments in C Program?
- Describe purposes and types of comments.
- Explain the use of print} and scanf( ) in C-language with examples. Logic = 4, Structure = 4
- Write a program using For loop to print table of any number.
OBJECTIVE (2022)
(1) For initializing a variable, we use_______operator.
(A) →
(B) =
(C) @
(D) ?
(2) Which of the following is a valid character in C-language?
(A) “here”
(B) “a”
(C) ‘a’
(D) 115
(3) In C-language, which of the following is logical operator?
(A) +
(B) <
(C) %
(D) NOT
(4) An if statement inside another if statement is called_____ structure.
(A) Nested
(B) Boxed
(C) Repeated
(D) Decomposed
(5) All of the following are control statements except:
(A) Sequential
(B) Repitition
(C) Selection
(D) Relation
(6) _____ Structure allows repetition of a set of instructions.
(A) Loop
(B) Conditional
(C) Control
(D) Data
(7) Using loop inside the loop is called:
(A) For
(B) While
(C) Simple
(D) Nested
(8) The values passed to a function are called:
(A) Bodies
(B) Return types
(C) Arrays
(D) Arguments
(9) What will be the output of this code?
Void abc ( )
{
printf(“Punjab”):
}
(A) Punjab
(B) Pun
(C) Pak
(D) Pakistan
(10) if there are three retun statements in the function body __ of them will be executed.
(A) One
(B) Two
(C) Three
(D) Four
SUBJECTIVE (2022)
Short Questions
- What do you know about text editor?
- What is compiler?
- While the purpose of syntax.
- What is the difference between printf( ) and scanf{ )?
- Define assignment operator.
- Define Modulus operator.
- What is sequential control?
- What is the output of the following:
int a=3, b= 5;
a=a+b;
if(a>8 && b <8)
b= a+b;
printf (“a = %d, b = %d”, a, b);
- Write the purpose of if statement.
- White structure of if-else statement.
- Define array.
- Declare an array of float type to store marks of 40 students.
- Identify the errors of this code. for (int x= 0, x <5; x++)
- printf(“PAKISTAN”);
- Write the output of this code.
int x;
for (x=0; x< 3;x++)
- print (” \n”);
- Define user-defined functions.
- How a function is called?
- Differentiate between arguments and parameters.
- What is meant by function body?
Long Questions
- What is variable? Write down the rules for naming variable in C-language.
- Explain the use of printf( ) and scanf( ) functions in C-language with examples. Structure = 4, Logic=4
- Write a program using “for” loop to print counting from 1-10.
Subjective (2021)
Short Questions
- Define debugging.
- Compare flowchart and algorithm.
- What does IF—–THEN statement do?
- Write a note on While—Wend loop.
- Define control structure.
- What is meant by selection structure?
- How does direct mode work in BASIC?
- Write a procedure to save a program in BASIC.
- Define Numeric Variable.
- Write the use of subscript variable in array.
- What is meant by one dimensional array?
- List two uses of array.
- Define sub-program.
- Write the syntax of user defined function.
- Define string functions.
- What are arguments?
- Define graphics.
- What is the use of PSET statement in BASIC?
Long Questions
- Define an algorithm. Explain the strategy for developing an algorithm.
- Write down the structure of BASIC program.
- Write a program to draw a Star.
10th class material
- Important Questions of Computer Science 10th Class
- Important questions for Class 10th Biology
- Important questions for Class 10th Chemistry
- Important Questions for 10th Class English
- Important Questions for 10th Class Islamiat
- Important Questions for 10th Pak Studies
- Important Questions for 10th Physics
- [All in 1] – 10th class Urdu past papers
- [All in 1 past papers] Pak Study – Punjab Board Pakistan