0% found this document useful (0 votes)
41 views5 pages

Test 1 (Student Copy)

Pias Test

Uploaded by

royalcamp2005
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
41 views5 pages

Test 1 (Student Copy)

Pias Test

Uploaded by

royalcamp2005
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

Computer

(1) What will be the output of the program?


#include<stdio.h>
int main()
{
int i=-3, j=2, k=0, m;
m = ++i && ++j && ++k;
printf("%d, %d, %d, %d\n", i, j, k, m);
return 0;
}
(a) -2, 3, 1, 1 (b) 2, 3, 1, 2
(c) 1, 2, 3, 1 (d) 3, 3, 1, 2
(2) Which of the following is invalid IP address?
(a) 172.68.20.100 (b) 172.20.23.1
(c) 203.12.15.1 (d) 315.68.20.100
(3) Which of the following are ingredients of data modeling?
(a) Entities / Objects (b) Attributes
(c) Relationship (d) All of above
(4) Which escape sequence can be used to begin a new line in C?
(a) \n (b) \a
(c) \r (d) \b
(5) What will be the output of following code?
int a = 4 , b = 2, c = 5 ;
if (a > b)
a=5;
if (c = = a)
a=6;
else
a=7;
printf (“%d” , a) ;
(a) 5 (b) 6
(c) 7 (d) 8
(6) What will be output of the following code?
{
int x, y, z;
x = 3;
y = 2;
z = 4;
printf(“%d %d %d ”, x+y, y+5, x+z);
}
(a) 5 7 7 (b) 7 5 7
(c) 7 7 5 (d) 5 7 5
(7) In _____every non-key attribute must depend on the key and all parts of the key.
(a) 1NF (b) 2NF
(c) 3NF (d) 4NF
(8) What will be the output of the program?
printf(“55\t”);
printf(“555”);
(a) 55 555 (b) Garbage value
(c) Error (d) 0
(9) Three axis servo robot which fits machines up to 300 tons?
(a) Remak RX 32 (b) FANUC
(c) W625H (d) M-16iB/20T

(10) What will be the output of the program? (Hint marks 48)
#include<stdio.h>
void main ( )
{
int marks;
printf (“ Enter your marks :”);
scanf(“%d”, & marks) ;
if (marks > = 40)
printf(“Congratulation”) ;
}
(a) Pass (b) Fail
(c) congratulation (d) Garbage
(11) What layer of OSI model does data compression?
(a) Network (b) Presentation
(c) Ring Network (d) Physical
(12) What is the output of this C code?
#include <stdio.h>
void main()
{
int n ;
n = 1;
while (n < = 10)
{
printf (%d\n”, n);
n++;
}
}
(a) 1 (b) 10
(c) 1 2 3 4 5 6 7 8 9 10 (d) None of these
(13) Create command is used to create:
(a) Table (b) Report
(c) Query (d) Form
(14) Two or more attributes having different names but same meaning are:
(a) Homonyms (b) Aliases
(c) Synonyms (d) None of these
(15) The order of stack is:
(a) F1FO (b) L1FO
(c) G1GO (d) FIGO
(16) A process of encoding for the purpose of data security is called:
(a) Password (b) Coding
(c) Encryption (d) Pin code
(17) A graphical query tool is known as:
(a) Query Grid (b) Design Grid
(c) Query Form (d) Design Form

(18) Which of the following statements correct about the below program?
#include<stdio.h>
#include<conio.h>
void main()
{
int n;
for(n=1; n<=5;n++)
printf(“%d\t%d\n”, n, n *n);
getch();
}
(a) 1, 2,3,4,5 (b) 1,4,9,16,25
(c) 1,5,10 (d) Both (a) & (b)
(19) In a __________ stream certain characters translations may occur.
(a) Text (b) Binary
(c) Character (d) Both (a) and (b)
(20) Referential integrity is applied on:
(a) Primary key (b) Foreign key
(c) Secondary key (d) Candidate key
(21) What is the output of this C code?
#include <stdio.h>
void main()
{
int x = 97;
int y = sizeof(x++);
printf("X is %d", x);
}
(a) X is 97 (b) X is 98
(c) X is 99 (d) Run time error
(22) What is the output of this C code?
float avg= 98.20;
printf(“Average = %5.2f”, avg);
(a) 98 (b) .20
(c) -98.20 (d) Average = 98.20
(23) Internet surfing is an example?
(a) Simplex (b) Half Duplex
(c) Full Duplex (d) Reverse Duplex
(24) Comment on the output of this C code?
void main()
{
char w1, w2, w3;
w1=’A’;
w2=’B’;
w3=’C’;
printf(“%c %c w3”, w1,w2);
}
(a) A B w3 (b) a b w1
(b) A b w2 (d) a b w4
(25) What is the output of this C code?
#include <stdio.h>
int main()
{
int a = 1, b = 1, c;
c = a++ + b;
printf("%d, %d", a, b);
}
(a) a = 1, b = 1 (b) a = 2, b = 1
(c) a = 1, b = 2 (d) a = 2, b = 2

(26) What is the output of this C code?


#include <stdio.h>
int main()
{
int a = 10, b = 10;
b--;
printf("%d, %d", a, b--);
}
(a) a = 10, b = 9 (b) a = 10, b = 8
(c) a = 5, b = 9 (d) a = 5, b = 8
(27) The parameters passed to a function in the function call are called __________
parameter.
(a) Actual (b) Formal
(c) Global (d) None of these
(28) What is the output of this C code?
#include <stdio.h>
int main()
{
int i = 2;
int j = ++i + i;
printf("%d\n", j);
}
(a) 6 (b) 5
(c) 4 (d) Compile time error
(29) What is the output of this C code?
#include <stdio.h>
void main()
{
int x = 0;
if (x = 0)
printf("Its zero\n");
else
printf("Its not zero\n");
}
(a) Its not zero (b) Its zero
(c) Run time error (d) None
(30) Which of the following is not a type of register?
(a) Accumulator register (b) Segment register
(c) Program counter (d) Math co-processor

You might also like