int[ ] ={5,6,7,8,9} What is the value of a[3]?
A) 9
B) 8
C) 7
D) 6

1 Answer

Answer :

B) 8

Related questions

Description : main() { Int a=3, b=2, c*d*e; d=&a; e=&b; c=*d+*e; } Which one of the given answers is correct? A) a=4, c-6 B) a=3, c=5 C) a=3, c=6 D) a=3, c=8

Last Answer : B) a=3, c=5

Description : If A and B are two fuzzy sets with membership functions μA(x) = {0.6, 0.5, 0.1, 0.7, 0.8} μB(x) = {0.9, 0.2, 0.6, 0.8, 0.5} Then the value of μ(A∪B)’(x) will be (A) {0.9, 0.5, 0.6, 0.8, 0.8} (B) {0.6, 0.2, 0.1, 0.7, 0.5} (C) {0.1, 0.5, 0.4, 0.2, 0.2} (D) {0.1, 0.5, 0.4, 0.2, 0.3}

Last Answer : (C) {0.1, 0.5, 0.4, 0.2, 0.2}

Description : If A and B are two fuzzy sets with membership functions µA(X) = {0.2, 0.5, 0.6, 0.1, 0.9} µB(X) = {0.1, 0.5, 0.2, 0.7, 0.8} Then the value of µA∩B will be (A) {0.2, 0.5, 0.6, 0.7, 0.9} (B) {0.2, 0.5, 0.2, 0.1, 0.8} (C) {0.1, 0.5, 0.6, 0.1, 0.8} (D) {0.1, 0.5, 0.2, 0.1, 0.8}

Last Answer : (D) {0.1, 0.5, 0.2, 0.1, 0.8}

Description : The correct way to round off a floating number x to an integer value is (A) y = (int)(x+0.5) (B) y = int(x+0.5) (C) y = (int)x+0.5 (D) y = (int)((int)x+0.5)

Last Answer : (A) y = (int)(x+0.5)

Description : What will be the output of the following segment of the program? main( ) { char *s = “hello world”; int i = 7; printf(“%, *s”, i, s); } (A) Syntax error (B) hello w (C) hello (D) o world

Last Answer : Answer: Marks given to all

Description : Assume that variable x resides at memory location 1234, y at 1111 and p at 2222. Int x=1, y=2, *p; p=&x; y=*p; What will be the value of y after execution of above code? A) 2 B) 1 C) 1234 D) 1111

Last Answer : C) 1234

Description : When the following code is executed what will be the value of x and y? int x = 1, y=0; y = x++; (A) 2, 1 (B) 2, 2 (C) 1, 1 (D) 1, 2

Last Answer : (A) 2, 1

Description : What is the value returned by the function f given below when n = 100 ? int f(int n)  { if (n==0) then return n;  else return n + f(n-2);  } (A) 2550 (B) 2556 (C) 5220 (D) 5520

Last Answer : (A) 2550

Description : What is the output of the following? i = 5 while True: if i%0O9 == 0: break print(i) i += 1 a) 5 6 7 8 b) 5 6 7 8 9 c) 5 6 7 8 9 10 11 12 13 14 15 …. d) error

Last Answer : d) error

Description : hat is the output of the following? i = 5 while True: if i%0O11 == 0: Page No 12 break print(i) i += 1 a) 5 6 7 8 9 10 b) 5 6 7 8 c) 5 6 d) error

Last Answer : b) 5 6 7 8

Description : The output generated by the LINUX command : $ seq 1 2 10 will be (A) 1 2 10 (B) 1 2 3 4 5 6 7 8 9 10 (C) 1 3 5 7 9 (D) 1 5 10

Last Answer : (C) 1 3 5 7 9

Description : Consider a program that consists of 8 pages (from 0 to 7) and we have 4 page frames in the physical memory for the pages. The page reference string is :  1 2 3 2 5 6 3 4 6 3 7 3 1 5 3 6 3 4 2 4 3 4 5 ... to fill available page frames with pages): (A) 9 and 6 (B) 10 and 7 (C) 9 and 7 (D) 10 and 6

Last Answer : (B) 10 and 7

Description : A job has four pages A, B, C, D and the main memory has two page frames only. The job needs to process its pages in following order: ABACABDBACD Assuming that a page interrupt occurs when a new page is brought in the main ... replacement algorithms are (A) 9 and 7 (B) 7 and 6 (C) 9 and 8 (D) 8 and 6

Last Answer : (C) 9 and 8

Description : How many times does the following code segment execute int x=1, y=10, z=1; do{y--; x++; y-=2; y=z; z++} while (y>1 && z

Last Answer : A) 1

Description : If m and n are int type variables, what will be the result of the expression m% n when m=5 and n=2 ? A) 0 B) 1 C) 2 D) None of the above

Last Answer : B) 1

Description : A method name myMethod( ) that needs two integer arguments is declared as A) public void myMethod( ); B) public void myMethod(int a, int b); C) public void myMethod(int a, b); D) public int myMethod(a, b);

Last Answer : B) public void myMethod(int a, int

Description : What will be the values of x, m and n after execution of the following statements? Int x, m, n; m=10; n=15; x= ++m + n++; A) x=25, m=10, n=15 B) x=27, m=10, n=15 C) x=26, m=11, n=16 D) x=27, m=11, n=16

Last Answer : C) x=26, m=11, n=16

Description : If an integer occupies 4 bytes and a character occupies 1 byte of memory, each element of the following structure would occupy how many bytes ? struct name { int age; char name[30]; }; A) 30 B) 32 C) 34 D) 36

Last Answer : C) 34

Description : Trace the error: void main( ) { int *b, &a; *b = 20 printf(“%d, %d”, a, *b) } (A) No error (B) Logical error (C) Syntax error (D) Semantic error

Last Answer : (C) Syntax error

Description : Which of the following has compilation error in C ? (A) int n = 32; (B) char ch = 65; (C) float f= (float) 3.2; (D) none of the above

Last Answer : D

Description : What does the following declaration mean ? int (*ptr) [10]; (A) ptr is an array of pointers of 10 integers. (B) ptr is a pointer to an array of 10 integers. (C) ptr is an array of 10 integers. (D) none of the above.

Last Answer : (B) ptr is a pointer to an array of 10 integers.

Description : What will be the output of the following ‘C’ code ? main ( ) { int x = 128; printf (“\n%d”, 1 + x++); } (A) 128 (B) 129 (C) 130 (D) 131

Last Answer :  (B) 129

Description : The Servlet Response interface enables a servlet to formulate a response for a client using the method ............... (A) void log(Exception e, String s) (B) void destroy() (C) int getServerPort() (D) void setContextType(String Type)

Last Answer : (D) void setContextType(String Type)

Description : A three dimensional array in C' is declared as int A[x][y][z]. Here, the address of an item at the location A[p][q][r] can be computed as follows (where w is the word length of an integer): (A) &A[0][0][0]+w(y*z*q+z*p+r) (B) &A ... *q+r) (C) &A[0][0][0]+w(x*y*p+z*q+r) (D) &A[0][0][0]+w(x*y*q+z*p+r)

Last Answer : Answer: B

Description : Consider the following JAVA program: public class First { public static int CBSE (int x) { if (x < 100) x = CBSE (x +10); return (x - 1); } public static void main (String[] args){ System.out.print(First.CBSE(60)); } } What does this program print? (1) 59 (2) 95 (3) 69 (4) 99

Last Answer : (2) 95 

Description : What is the output of the following? i = 1 while True: if i%2 == 0: break print(i) i += 2 a) 1 Page No 13 b) 1 2 c) 1 2 3 4 5 6 … d) 1 3 5 7 9 11 …

Last Answer : d) 1 3 5 7 9 11 …

Description : Suppose that the virtual Address space has eight pages and physical memory with four page frames. If LRU page replacement algorithm is used, .............. number of page faults occur with the reference string. 0 2 1 3 5 4 6 3 7 4 7 3 3 5 5 3 1 1 1 7 2 3 4 1 (A) 11 (B) 12 (C) 10 (D) 9

Last Answer : (A) 11

Description : The end points of a given line are (0, 0) and (6, 18). Compute each value of y as x steps from 0 to 3, by using equation of straight line : (A) For x=0, y=0; x=1, y=3; x=2, y=6; x=3, y=9 (B) For x=0, y=1; x=1, y=3; x=2, ... x=1, y=3; x=2, y=6; x=3, y=9 (D) For x=0, y=0; x=1, y=3; x=2, y=4; x=3, y=6

Last Answer : Answer: A

Description : Compute the value of adding the following two fuzzy integers: A = {(0.3,1), (0.6,2), (1,3), (0.7,4), (0.2,5)} B = {(0.5,11), (1,12), (0.5,13)} Where fuzzy addition is defined as μA+B(z) = maxx+y=z (min(μA(x), μB( ... ,18)} (D) {(0.3,12), (0.5,13), (0.6,14), (1,15), (0.7,16), (0.5,17), (0.2,18)}

Last Answer : (D) {(0.3,12), (0.5,13), (0.6,14), (1,15), (0.7,16), (0.5,17), (0.2,18)} 

Description : Maximum font size in HTML is ........... A) 6 B) 7 C) 5 D) 8

Last Answer : B) 7

Description : Let A and B be two fuzzy integers defined as: A={(1,0.3), (2,0.6), (3,1), (4,0.7), (5,0.2)} B={(10,0.5), (11,1), (12,0.5)} Using fuzzy arithmetic operation given by (A) {(11,0.8), (13,1), (15,1)} ( ... ,0.2)} (D) {(11,0.3), (12,0.5), (13,0.6), (14,1), (15,0.7), (16,0.5), (17,0.2)}

Last Answer : (D) {(11,0.3), (12,0.5), (13,0.6), (14,1), (15,0.7), (16,0.5), (17,0.2)}

Description : A LRU page replacement is used with four page frames and eight pages. How many page faults will occur with the reference string 0172327103 if the four frames are initially empty? (A) 6 (B) 7 (C) 5 (D) 8

Last Answer : (B) 7

Description : Suppose ORACLE relation R(A, B) currently has tuples {(1, 2), (1, 3), (3, 4)} and relation S(B, C) currently has {(2, 5), (4, 6), (7, 8)}. Consider the following two SQL queries SQ1 and SQ2 ... (A) 2 and 6 respectively (B) 6 and 2 respectively (C) 2 and 4 respectively (D) 4 and 2 respectively

Last Answer : (D) 4 and 2 respectively

Description : Let R be the rectangular window against which the lines are to be clipped using 2D Sutherland-Cohen line clipping algorithm. The rectangular window has lower left-hand corner at (-5,1) and upper righthand corner at (3,7). ... s) is/are candidate for clipping? (A) AB (B) CD (C) EF (D) AB and CD

Last Answer : (D) AB and CD

Description : The simplified function in product of sums of Boolean function F(W, X, Y, Z) = Σ(0, 1, 2, 5, 8, 9, 10) is (A) (W' + X') (Y' + Z') (X' + Z) (B) (W' + X') (Y' + Z') (X' + Z') (C) (W' + X') (Y' + Z) (X' + Z) (D) (W' + X') (Y + Z') (X' + Z)

Last Answer : (A) (W' + X') (Y' + Z') (X' + Z)

Description : Consider a code with five valid code words of length ten : 0000000000, 0000011111, 1111100000, 1110000011, 1111111111 Hamming distance of the code is (A) 5 (B) 10 (C) 8 (D) 9

Last Answer : Answer: Marks to all

Description : A perceptron has input weights W1 = -3.9 and W2 = 1.1 with threshold value T = 0.3. What output does it give for the input x1 = 1.3 and x2 = 2.2? (A) -2.65 (B) -2.30 (B) 0 (D) 1

Last Answer : Answer: C

Description : Five jobs A, B, C, D and E are waiting in Ready Queue. Their expected runtimes are 9, 6, 3, 5 and x respectively. All jobs entered in Ready queue at time zero. They must run in ............. order to minimize average response time if 3 < ... , C (B) C, E, D, B, A (C) E, D, C, B, A (D) C, B, A, E, D

Last Answer : (B) C, E, D, B, A

Description : What will be the output? >>>t = (1, 2, 4, 3, 8, 9) >>>[t[i] for i in range(0, len(t), 2)] a) [2, 3, 9]. b) [1, 2, 4, 3, 8, 9]. c) [1, 4, 8]. d) (1, 4, 8)

Last Answer : c) [1, 4, 8].

Description : The number of flip-flops required to design a modulo-272 counter is: (A) 8 (B) 9 (C) 27 (D) 11

Last Answer : 9

Description : Looking for source and pricing for nipple O2 adaptor for Hand Held Nebulizers. Constant Flow 7-9 L/min plugs int O2 outlet.?

Last Answer : you can expect to pay over 40 dolalrs

Description : If a is an integer variable, a=7/3; will return a value A) 2.5 B) 3 C) 0 D) 2

Last Answer : D) 2

Description : In RSA algorithm,if p=5,q=7,e=7and message=3. What will be the value of ciphertext ?

Last Answer : 17

Description : Given that x=7.5, j=-1.0, n=1.0, m=2.0 the value of --x+j == x>n>=m is: (A) 0 (B) 1 (C) 2 (D) 3

Last Answer : (A) 0 

Description : Using p=3, q=13, d=7 and e=3 in the RSA algorithm, what is the value of ciphertext for a plain text 5? (A) 13 (B) 21 (C) 26 (D) 33

Last Answer : Answer: Marks to all Explanation: p=3, q=13, d=7, e=3, M=5, C=? C = Me mod n n = p*q  = 3*13 = 39 C = 53 mod 39 = 8 Answer is 8.

Description : Consider a system having ‘m’ resources of the same type. These resources are shared by three processes P1, P2 and P3 which have peak demands of 2, 5 and 7 resources respectively. For what value of ‘m’ deadlock will not occur? (A) 70 (B) 14 (C) 13 (D) 7

Last Answer : (B) 14

Description : Consider the fractional knapsack instance n = 4, (p1, p2, p3, p4) = (10, 10, 12, 18), (w1, w2, w3, w4) = (2, 4, 6, 9) and M = 15. The maximum profit is given by (Assume p and w denotes profit and weight of objects respectively) (A) 40 (B) 38 (C) 32 (D) 30

Last Answer : (B) 38

Description : What is the value of the postfix expression ? a b c d + - * (where a = 8, b = 4, c = 2 and d = 5) (A) -3/8 (B) -8/3 (C) 24 (D) -24

Last Answer : (D) -24

Description : Using the RSA public key crypto system, if p=13, q=31 and d=7, then the value of e is (A) 101 (B) 105 (C) 103 (D) 107

Last Answer : (C) 103 Explanation: Basic RSA Algorithm: 1. Choose two primes, p & q. 2. Compute n=p*q and z=(p-1)*(q-1). 3. Choose a number relatively prime to z and call it d. 4. Find e such that e*d= ... each of these in turn by 7 to see which is divisible by 7, we find that 721/7 = 103, hence e = 103. 

Description : The order of a leaf node in a B+ tree is the maximum number of children it can have. Suppose that block size is 1 kilobytes, the child pointer takes 7 bytes long and search field value takes 14 bytes long. The order of the leaf node is ............ (1) 16 (2) 63 (3) 64 (4) 65

Last Answer : Answer: All